| 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" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 | 22 |
| 23 class BeginFrameSource; | 23 class BeginFrameSource; |
| 24 struct ManagedMemoryPolicy; | 24 struct ManagedMemoryPolicy; |
| 25 | 25 |
| 26 class CC_EXPORT OutputSurfaceClient { | 26 class CC_EXPORT OutputSurfaceClient { |
| 27 public: | 27 public: |
| 28 // A notification that the swap of the backbuffer to the hardware is complete | 28 // A notification that the swap of the backbuffer to the hardware is complete |
| 29 // and is now visible to the user. | 29 // and is now visible to the user. |
| 30 virtual void DidReceiveSwapBuffersAck() = 0; | 30 virtual void DidReceiveSwapBuffersAck() = 0; |
| 31 | 31 |
| 32 // The OutputSurface is lost when the ContextProviders held by it | |
| 33 // encounter an error. In this case the OutputSurface (and the | |
| 34 // ContextProviders) must be recreated. | |
| 35 virtual void DidLoseOutputSurface() = 0; | |
| 36 | |
| 37 // For surfaceless/ozone implementations to create damage for the next frame. | 32 // For surfaceless/ozone implementations to create damage for the next frame. |
| 38 virtual void SetNeedsRedrawRect(const gfx::Rect& damage_rect) = 0; | 33 virtual void SetNeedsRedrawRect(const gfx::Rect& damage_rect) = 0; |
| 39 | 34 |
| 40 // For overlays. | 35 // For overlays. |
| 41 virtual void DidReceiveTextureInUseResponses( | 36 virtual void DidReceiveTextureInUseResponses( |
| 42 const gpu::TextureInUseResponses& responses) = 0; | 37 const gpu::TextureInUseResponses& responses) = 0; |
| 43 | 38 |
| 44 protected: | 39 protected: |
| 45 virtual ~OutputSurfaceClient() {} | 40 virtual ~OutputSurfaceClient() {} |
| 46 }; | 41 }; |
| 47 | 42 |
| 48 } // namespace cc | 43 } // namespace cc |
| 49 | 44 |
| 50 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ | 45 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ |
| OLD | NEW |