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 30 matching lines...) Expand all Loading... |
41 virtual void SetExternalDrawConstraints(const gfx::Transform& transform, | 41 virtual void SetExternalDrawConstraints(const gfx::Transform& transform, |
42 const gfx::Rect& viewport, | 42 const gfx::Rect& viewport, |
43 const gfx::Rect& clip, | 43 const gfx::Rect& clip, |
44 bool valid_for_tile_management) = 0; | 44 bool valid_for_tile_management) = 0; |
45 virtual void SetMemoryPolicy(const ManagedMemoryPolicy& policy) = 0; | 45 virtual void SetMemoryPolicy(const ManagedMemoryPolicy& policy) = 0; |
46 // If set, |callback| will be called subsequent to each new tree activation, | 46 // If set, |callback| will be called subsequent to each new tree activation, |
47 // regardless of the compositor visibility or damage. |callback| must remain | 47 // regardless of the compositor visibility or damage. |callback| must remain |
48 // valid for the lifetime of the OutputSurfaceClient or until unregisted -- | 48 // valid for the lifetime of the OutputSurfaceClient or until unregisted -- |
49 // use SetTreeActivationCallback(base::Closure()) to unregister it. | 49 // use SetTreeActivationCallback(base::Closure()) to unregister it. |
50 virtual void SetTreeActivationCallback(const base::Closure& callback) = 0; | 50 virtual void SetTreeActivationCallback(const base::Closure& callback) = 0; |
| 51 virtual int GetSourceFrameNumber() = 0; |
51 | 52 |
52 protected: | 53 protected: |
53 virtual ~OutputSurfaceClient() {} | 54 virtual ~OutputSurfaceClient() {} |
54 }; | 55 }; |
55 | 56 |
56 } // namespace cc | 57 } // namespace cc |
57 | 58 |
58 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ | 59 #endif // CC_OUTPUT_OUTPUT_SURFACE_CLIENT_H_ |
OLD | NEW |