| 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 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| (...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 150 | 150 |
| 151 virtual void DidLoseOutputSurface(); | 151 virtual void DidLoseOutputSurface(); |
| 152 void SetMemoryPolicy(const ManagedMemoryPolicy& policy); | 152 void SetMemoryPolicy(const ManagedMemoryPolicy& policy); |
| 153 | 153 |
| 154 // Support for a pull-model where draws are requested by the output surface. | 154 // Support for a pull-model where draws are requested by the output surface. |
| 155 // | 155 // |
| 156 // OutputSurface::Invalidate is called by the compositor to notify that | 156 // OutputSurface::Invalidate is called by the compositor to notify that |
| 157 // there's new content. | 157 // there's new content. |
| 158 virtual void Invalidate() {} | 158 virtual void Invalidate() {} |
| 159 | 159 |
| 160 virtual void ProcessCALayers(const CALayerOverlayList& ca_layer_overlays) {} |
| 161 |
| 160 // Updates the worker context provider's visibility, freeing GPU resources if | 162 // Updates the worker context provider's visibility, freeing GPU resources if |
| 161 // appropriate. | 163 // appropriate. |
| 162 virtual void SetWorkerContextShouldAggressivelyFreeResources(bool is_visible); | 164 virtual void SetWorkerContextShouldAggressivelyFreeResources(bool is_visible); |
| 163 | 165 |
| 164 // If this returns true, then the surface will not attempt to draw. | 166 // If this returns true, then the surface will not attempt to draw. |
| 165 virtual bool SurfaceIsSuspendForRecycle() const; | 167 virtual bool SurfaceIsSuspendForRecycle() const; |
| 166 | 168 |
| 167 // base::trace_event::MemoryDumpProvider implementation. | 169 // base::trace_event::MemoryDumpProvider implementation. |
| 168 bool OnMemoryDump(const base::trace_event::MemoryDumpArgs& args, | 170 bool OnMemoryDump(const base::trace_event::MemoryDumpArgs& args, |
| 169 base::trace_event::ProcessMemoryDump* pmd) override; | 171 base::trace_event::ProcessMemoryDump* pmd) override; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 192 bool external_stencil_test_enabled_ = false; | 194 bool external_stencil_test_enabled_ = false; |
| 193 | 195 |
| 194 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; | 196 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; |
| 195 | 197 |
| 196 DISALLOW_COPY_AND_ASSIGN(OutputSurface); | 198 DISALLOW_COPY_AND_ASSIGN(OutputSurface); |
| 197 }; | 199 }; |
| 198 | 200 |
| 199 } // namespace cc | 201 } // namespace cc |
| 200 | 202 |
| 201 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_ | 203 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_ |
| OLD | NEW |