| 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_H_ | 5 #ifndef CC_OUTPUT_OUTPUT_SURFACE_H_ |
| 6 #define CC_OUTPUT_OUTPUT_SURFACE_H_ | 6 #define CC_OUTPUT_OUTPUT_SURFACE_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 // The implementation may destroy or steal the contents of the CompositorFrame | 114 // The implementation may destroy or steal the contents of the CompositorFrame |
| 115 // passed in (though it will not take ownership of the CompositorFrame | 115 // passed in (though it will not take ownership of the CompositorFrame |
| 116 // itself). | 116 // itself). |
| 117 virtual void SwapBuffers(CompositorFrame* frame); | 117 virtual void SwapBuffers(CompositorFrame* frame); |
| 118 virtual void OnSwapBuffersComplete(); | 118 virtual void OnSwapBuffersComplete(); |
| 119 | 119 |
| 120 // Notifies frame-rate smoothness preference. If true, all non-critical | 120 // Notifies frame-rate smoothness preference. If true, all non-critical |
| 121 // processing should be stopped, or lowered in priority. | 121 // processing should be stopped, or lowered in priority. |
| 122 virtual void UpdateSmoothnessTakesPriority(bool prefer_smoothness) {} | 122 virtual void UpdateSmoothnessTakesPriority(bool prefer_smoothness) {} |
| 123 | 123 |
| 124 // Requests a BeginFrame notification from the output surface. The | |
| 125 // notification will be delivered by calling | |
| 126 // OutputSurfaceClient::BeginFrame until the callback is disabled. | |
| 127 virtual void SetNeedsBeginFrame(bool enable) {} | |
| 128 | |
| 129 bool HasClient() { return !!client_; } | 124 bool HasClient() { return !!client_; } |
| 130 | 125 |
| 131 // Get the class capable of informing cc of hardware overlay capability. | 126 // Get the class capable of informing cc of hardware overlay capability. |
| 132 OverlayCandidateValidator* overlay_candidate_validator() const { | 127 OverlayCandidateValidator* overlay_candidate_validator() const { |
| 133 return overlay_candidate_validator_.get(); | 128 return overlay_candidate_validator_.get(); |
| 134 } | 129 } |
| 135 | 130 |
| 136 void DidLoseOutputSurface(); | 131 void DidLoseOutputSurface(); |
| 137 void SetMemoryPolicy(const ManagedMemoryPolicy& policy); | 132 void SetMemoryPolicy(const ManagedMemoryPolicy& policy); |
| 138 | 133 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 bool external_stencil_test_enabled_; | 170 bool external_stencil_test_enabled_; |
| 176 | 171 |
| 177 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; | 172 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; |
| 178 | 173 |
| 179 DISALLOW_COPY_AND_ASSIGN(OutputSurface); | 174 DISALLOW_COPY_AND_ASSIGN(OutputSurface); |
| 180 }; | 175 }; |
| 181 | 176 |
| 182 } // namespace cc | 177 } // namespace cc |
| 183 | 178 |
| 184 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_ | 179 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_ |
| OLD | NEW |