OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CC_PROXY_H_ | 5 #ifndef CC_PROXY_H_ |
6 #define CC_PROXY_H_ | 6 #define CC_PROXY_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/memory/scoped_ptr.h" |
10 #include "base/time.h" | 11 #include "base/time.h" |
11 #include "base/memory/scoped_ptr.h" | |
12 #include "cc/cc_export.h" | 12 #include "cc/cc_export.h" |
| 13 #include "skia/ext/refptr.h" |
| 14 #include "third_party/skia/include/core/SkPicture.h" |
13 | 15 |
14 namespace gfx { | 16 namespace gfx { |
15 class Rect; | 17 class Rect; |
16 class Vector2d; | 18 class Vector2d; |
17 } | 19 } |
18 | 20 |
19 namespace cc { | 21 namespace cc { |
20 | 22 |
21 class Thread; | 23 class Thread; |
22 struct RenderingStats; | 24 struct RenderingStats; |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 | 91 |
90 // Forces 3D commands on all contexts to wait for all previous SwapBuffers t
o finish before executing in the GPU | 92 // Forces 3D commands on all contexts to wait for all previous SwapBuffers t
o finish before executing in the GPU |
91 // process. | 93 // process. |
92 virtual void forceSerializeOnSwapBuffers() = 0; | 94 virtual void forceSerializeOnSwapBuffers() = 0; |
93 | 95 |
94 // Maximum number of sub-region texture updates supported for each commit. | 96 // Maximum number of sub-region texture updates supported for each commit. |
95 virtual size_t maxPartialTextureUpdates() const = 0; | 97 virtual size_t maxPartialTextureUpdates() const = 0; |
96 | 98 |
97 virtual void acquireLayerTextures() = 0; | 99 virtual void acquireLayerTextures() = 0; |
98 | 100 |
| 101 virtual skia::RefPtr<SkPicture> capturePicture() = 0; |
| 102 |
99 // Testing hooks | 103 // Testing hooks |
100 virtual void loseOutputSurface() = 0; | 104 virtual void loseOutputSurface() = 0; |
101 virtual bool commitPendingForTesting() = 0; | 105 virtual bool commitPendingForTesting() = 0; |
102 | 106 |
103 protected: | 107 protected: |
104 explicit Proxy(scoped_ptr<Thread> implThread); | 108 explicit Proxy(scoped_ptr<Thread> implThread); |
105 friend class DebugScopedSetImplThread; | 109 friend class DebugScopedSetImplThread; |
106 friend class DebugScopedSetMainThread; | 110 friend class DebugScopedSetMainThread; |
107 friend class DebugScopedSetMainThreadBlocked; | 111 friend class DebugScopedSetMainThreadBlocked; |
108 | 112 |
(...skipping 29 matching lines...) Expand all Loading... |
138 class DebugScopedSetMainThreadBlocked { | 142 class DebugScopedSetMainThreadBlocked { |
139 public: | 143 public: |
140 explicit DebugScopedSetMainThreadBlocked(Proxy*) { } | 144 explicit DebugScopedSetMainThreadBlocked(Proxy*) { } |
141 ~DebugScopedSetMainThreadBlocked() { } | 145 ~DebugScopedSetMainThreadBlocked() { } |
142 }; | 146 }; |
143 #endif | 147 #endif |
144 | 148 |
145 } | 149 } |
146 | 150 |
147 #endif // CC_PROXY_H_ | 151 #endif // CC_PROXY_H_ |
OLD | NEW |