OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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_TREES_LAYER_TREE_HOST_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_H_ |
6 #define CC_TREES_LAYER_TREE_HOST_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_H_ |
7 | 7 |
8 #include <limits> | 8 #include <limits> |
9 #include <list> | 9 #include <list> |
10 #include <string> | 10 #include <string> |
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 // Call this function when you expect there to be a swap buffer. | 288 // Call this function when you expect there to be a swap buffer. |
289 // See swap_promise.h for how to use SwapPromise. | 289 // See swap_promise.h for how to use SwapPromise. |
290 void QueueSwapPromise(scoped_ptr<SwapPromise> swap_promise); | 290 void QueueSwapPromise(scoped_ptr<SwapPromise> swap_promise); |
291 | 291 |
292 void BreakSwapPromises(SwapPromise::DidNotSwapReason reason); | 292 void BreakSwapPromises(SwapPromise::DidNotSwapReason reason); |
293 | 293 |
294 protected: | 294 protected: |
295 LayerTreeHost(LayerTreeHostClient* client, | 295 LayerTreeHost(LayerTreeHostClient* client, |
296 SharedBitmapManager* manager, | 296 SharedBitmapManager* manager, |
297 const LayerTreeSettings& settings); | 297 const LayerTreeSettings& settings); |
298 void InitializeThreaded( | 298 bool InitializeThreaded( |
299 scoped_refptr<base::SingleThreadTaskRunner> impl_task_runner); | 299 scoped_refptr<base::SingleThreadTaskRunner> impl_task_runner); |
300 void InitializeSingleThreaded( | 300 bool InitializeSingleThreaded( |
301 LayerTreeHostSingleThreadClient* single_thread_client); | 301 LayerTreeHostSingleThreadClient* single_thread_client); |
302 void InitializeForTesting(scoped_ptr<Proxy> proxy_for_testing); | 302 bool InitializeForTesting(scoped_ptr<Proxy> proxy_for_testing); |
303 void SetOutputSurfaceLostForTesting(bool is_lost) { | 303 void SetOutputSurfaceLostForTesting(bool is_lost) { |
304 output_surface_lost_ = is_lost; | 304 output_surface_lost_ = is_lost; |
305 } | 305 } |
306 | 306 |
307 MicroBenchmarkController micro_benchmark_controller_; | 307 MicroBenchmarkController micro_benchmark_controller_; |
308 | 308 |
309 private: | 309 private: |
310 void InitializeProxy(scoped_ptr<Proxy> proxy); | 310 bool InitializeProxy(scoped_ptr<Proxy> proxy); |
311 | 311 |
312 void PaintLayerContents( | 312 void PaintLayerContents( |
313 const RenderSurfaceLayerList& render_surface_layer_list, | 313 const RenderSurfaceLayerList& render_surface_layer_list, |
314 ResourceUpdateQueue* queue, | 314 ResourceUpdateQueue* queue, |
315 bool* did_paint_content, | 315 bool* did_paint_content, |
316 bool* need_more_updates); | 316 bool* need_more_updates); |
317 void PaintMasksForRenderSurface(Layer* render_surface_layer, | 317 void PaintMasksForRenderSurface(Layer* render_surface_layer, |
318 ResourceUpdateQueue* queue, | 318 ResourceUpdateQueue* queue, |
319 bool* did_paint_content, | 319 bool* did_paint_content, |
320 bool* need_more_updates); | 320 bool* need_more_updates); |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
437 SharedBitmapManager* shared_bitmap_manager_; | 437 SharedBitmapManager* shared_bitmap_manager_; |
438 | 438 |
439 ScopedPtrVector<SwapPromise> swap_promise_list_; | 439 ScopedPtrVector<SwapPromise> swap_promise_list_; |
440 | 440 |
441 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 441 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
442 }; | 442 }; |
443 | 443 |
444 } // namespace cc | 444 } // namespace cc |
445 | 445 |
446 #endif // CC_TREES_LAYER_TREE_HOST_H_ | 446 #endif // CC_TREES_LAYER_TREE_HOST_H_ |
OLD | NEW |