OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ | 5 #ifndef CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ |
6 #define CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ | 6 #define CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
11 #include "cc/base/cc_export.h" | 11 #include "cc/base/cc_export.h" |
12 #include "cc/output/context_provider.h" | 12 #include "cc/output/context_provider.h" |
13 #include "cc/resources/returned_resource.h" | 13 #include "cc/resources/returned_resource.h" |
14 #include "gpu/command_buffer/common/texture_in_use_response.h" | 14 #include "gpu/command_buffer/common/texture_in_use_response.h" |
15 #include "ui/gfx/geometry/rect.h" | 15 #include "ui/gfx/geometry/rect.h" |
16 | 16 |
17 namespace gfx { | |
18 class Transform; | |
19 } | |
20 | |
21 namespace cc { | 17 namespace cc { |
22 | 18 |
23 class BeginFrameSource; | |
24 struct ManagedMemoryPolicy; | |
25 | |
26 class CC_EXPORT OutputSurfaceClient { | 19 class CC_EXPORT OutputSurfaceClient { |
27 public: | 20 public: |
28 // A notification that the swap of the backbuffer to the hardware is complete | 21 // A notification that the swap of the backbuffer to the hardware is complete |
29 // and is now visible to the user. | 22 // and is now visible to the user. |
30 virtual void DidReceiveSwapBuffersAck() = 0; | 23 virtual void DidReceiveSwapBuffersAck() = 0; |
31 | 24 |
32 // For surfaceless/ozone implementations to create damage for the next frame. | 25 // For surfaceless/ozone implementations to create damage for the next frame. |
33 virtual void SetNeedsRedrawRect(const gfx::Rect& damage_rect) = 0; | 26 virtual void SetNeedsRedrawRect(const gfx::Rect& damage_rect) = 0; |
34 | 27 |
35 // For overlays. | 28 // For overlays. |
36 virtual void DidReceiveTextureInUseResponses( | 29 virtual void DidReceiveTextureInUseResponses( |
37 const gpu::TextureInUseResponses& responses) = 0; | 30 const gpu::TextureInUseResponses& responses) = 0; |
38 | 31 |
39 protected: | 32 protected: |
40 virtual ~OutputSurfaceClient() {} | 33 virtual ~OutputSurfaceClient() {} |
41 }; | 34 }; |
42 | 35 |
43 } // namespace cc | 36 } // namespace cc |
44 | 37 |
45 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ | 38 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ |
OLD | NEW |