| 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_IMPL_H_ | 5 #ifndef CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| 6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "cc/input/top_controls_manager_client.h" | 24 #include "cc/input/top_controls_manager_client.h" |
| 25 #include "cc/layers/layer_lists.h" | 25 #include "cc/layers/layer_lists.h" |
| 26 #include "cc/layers/render_pass_sink.h" | 26 #include "cc/layers/render_pass_sink.h" |
| 27 #include "cc/output/begin_frame_args.h" | 27 #include "cc/output/begin_frame_args.h" |
| 28 #include "cc/output/managed_memory_policy.h" | 28 #include "cc/output/managed_memory_policy.h" |
| 29 #include "cc/output/output_surface_client.h" | 29 #include "cc/output/output_surface_client.h" |
| 30 #include "cc/output/renderer.h" | 30 #include "cc/output/renderer.h" |
| 31 #include "cc/quads/render_pass.h" | 31 #include "cc/quads/render_pass.h" |
| 32 #include "cc/resources/resource_provider.h" | 32 #include "cc/resources/resource_provider.h" |
| 33 #include "cc/resources/tile_manager.h" | 33 #include "cc/resources/tile_manager.h" |
| 34 #include "cc/resources/tile_priority_queue.h" |
| 34 #include "cc/scheduler/draw_result.h" | 35 #include "cc/scheduler/draw_result.h" |
| 35 #include "skia/ext/refptr.h" | 36 #include "skia/ext/refptr.h" |
| 36 #include "third_party/skia/include/core/SkColor.h" | 37 #include "third_party/skia/include/core/SkColor.h" |
| 37 #include "ui/gfx/rect.h" | 38 #include "ui/gfx/rect.h" |
| 38 | 39 |
| 39 namespace cc { | 40 namespace cc { |
| 40 | 41 |
| 41 class CompletionEvent; | 42 class CompletionEvent; |
| 42 class CompositorFrameMetadata; | 43 class CompositorFrameMetadata; |
| 43 class DebugRectHistory; | 44 class DebugRectHistory; |
| (...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 // excludes the URL bar and non-overlay scrollbars and is in DIP (and | 226 // excludes the URL bar and non-overlay scrollbars and is in DIP (and |
| 226 // invariant relative to page scale). | 227 // invariant relative to page scale). |
| 227 gfx::SizeF UnscaledScrollableViewportSize() const; | 228 gfx::SizeF UnscaledScrollableViewportSize() const; |
| 228 float VerticalAdjust() const; | 229 float VerticalAdjust() const; |
| 229 | 230 |
| 230 // RendererClient implementation. | 231 // RendererClient implementation. |
| 231 virtual void SetFullRootLayerDamage() OVERRIDE; | 232 virtual void SetFullRootLayerDamage() OVERRIDE; |
| 232 virtual void RunOnDemandRasterTask(Task* on_demand_raster_task) OVERRIDE; | 233 virtual void RunOnDemandRasterTask(Task* on_demand_raster_task) OVERRIDE; |
| 233 | 234 |
| 234 // TileManagerClient implementation. | 235 // TileManagerClient implementation. |
| 235 virtual const std::vector<PictureLayerImpl*>& GetPictureLayers() OVERRIDE; | 236 virtual const std::vector<PictureLayerImpl*>& GetPictureLayers() |
| 237 const OVERRIDE; |
| 236 virtual void NotifyReadyToActivate() OVERRIDE; | 238 virtual void NotifyReadyToActivate() OVERRIDE; |
| 237 virtual void NotifyTileStateChanged(const Tile* tile) OVERRIDE; | 239 virtual void NotifyTileStateChanged(const Tile* tile) OVERRIDE; |
| 240 virtual RasterTileQueue* GetRasterQueue(TreePriority tree_priority) OVERRIDE; |
| 241 virtual EvictionTileQueue* GetEvictionQueue( |
| 242 TreePriority tree_prirority) OVERRIDE; |
| 238 | 243 |
| 239 // ScrollbarAnimationControllerClient implementation. | 244 // ScrollbarAnimationControllerClient implementation. |
| 240 virtual void PostDelayedScrollbarFade(const base::Closure& start_fade, | 245 virtual void PostDelayedScrollbarFade(const base::Closure& start_fade, |
| 241 base::TimeDelta delay) OVERRIDE; | 246 base::TimeDelta delay) OVERRIDE; |
| 242 virtual void SetNeedsScrollbarAnimationFrame() OVERRIDE; | 247 virtual void SetNeedsScrollbarAnimationFrame() OVERRIDE; |
| 243 | 248 |
| 244 // OutputSurfaceClient implementation. | 249 // OutputSurfaceClient implementation. |
| 245 virtual void DeferredInitialize() OVERRIDE; | 250 virtual void DeferredInitialize() OVERRIDE; |
| 246 virtual void ReleaseGL() OVERRIDE; | 251 virtual void ReleaseGL() OVERRIDE; |
| 247 virtual void CommitVSyncParameters(base::TimeTicks timebase, | 252 virtual void CommitVSyncParameters(base::TimeTicks timebase, |
| (...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 490 LayerTreeHostImplClient* client_; | 495 LayerTreeHostImplClient* client_; |
| 491 Proxy* proxy_; | 496 Proxy* proxy_; |
| 492 | 497 |
| 493 private: | 498 private: |
| 494 void CreateAndSetRenderer(); | 499 void CreateAndSetRenderer(); |
| 495 void CreateAndSetTileManager(); | 500 void CreateAndSetTileManager(); |
| 496 void DestroyTileManager(); | 501 void DestroyTileManager(); |
| 497 void ReleaseTreeResources(); | 502 void ReleaseTreeResources(); |
| 498 void EnforceZeroBudget(bool zero_budget); | 503 void EnforceZeroBudget(bool zero_budget); |
| 499 | 504 |
| 505 void GetPairedPictureLayers(std::vector<PairedPictureLayer>* layers) const; |
| 506 |
| 500 bool UsePendingTreeForSync() const; | 507 bool UsePendingTreeForSync() const; |
| 501 bool UseZeroCopyTextureUpload() const; | 508 bool UseZeroCopyTextureUpload() const; |
| 502 bool UseOneCopyTextureUpload() const; | 509 bool UseOneCopyTextureUpload() const; |
| 503 | 510 |
| 504 void ScrollViewportBy(gfx::Vector2dF scroll_delta); | 511 void ScrollViewportBy(gfx::Vector2dF scroll_delta); |
| 505 void AnimatePageScale(base::TimeTicks monotonic_time); | 512 void AnimatePageScale(base::TimeTicks monotonic_time); |
| 506 void AnimateScrollbars(base::TimeTicks monotonic_time); | 513 void AnimateScrollbars(base::TimeTicks monotonic_time); |
| 507 void AnimateTopControls(base::TimeTicks monotonic_time); | 514 void AnimateTopControls(base::TimeTicks monotonic_time); |
| 508 | 515 |
| 509 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta( | 516 gfx::Vector2dF ScrollLayerWithViewportSpaceDelta( |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 683 | 690 |
| 684 SharedBitmapManager* shared_bitmap_manager_; | 691 SharedBitmapManager* shared_bitmap_manager_; |
| 685 int id_; | 692 int id_; |
| 686 | 693 |
| 687 std::set<SwapPromiseMonitor*> swap_promise_monitor_; | 694 std::set<SwapPromiseMonitor*> swap_promise_monitor_; |
| 688 | 695 |
| 689 size_t transfer_buffer_memory_limit_; | 696 size_t transfer_buffer_memory_limit_; |
| 690 | 697 |
| 691 std::vector<PictureLayerImpl*> picture_layers_; | 698 std::vector<PictureLayerImpl*> picture_layers_; |
| 692 | 699 |
| 700 RasterTileQueue raster_queue_; |
| 701 EvictionTileQueue eviction_queue_; |
| 702 |
| 693 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 703 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
| 694 }; | 704 }; |
| 695 | 705 |
| 696 } // namespace cc | 706 } // namespace cc |
| 697 | 707 |
| 698 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 708 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| OLD | NEW |