| 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 <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <bitset> | 10 #include <bitset> |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 OFF_DEVICE, | 91 OFF_DEVICE, |
| 92 OFF_VIEWPORT, | 92 OFF_VIEWPORT, |
| 93 MSAA_CONTENT, | 93 MSAA_CONTENT, |
| 94 OFF_CONTENT | 94 OFF_CONTENT |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 // LayerTreeHost->Proxy callback interface. | 97 // LayerTreeHost->Proxy callback interface. |
| 98 class LayerTreeHostImplClient { | 98 class LayerTreeHostImplClient { |
| 99 public: | 99 public: |
| 100 virtual void DidLoseOutputSurfaceOnImplThread() = 0; | 100 virtual void DidLoseOutputSurfaceOnImplThread() = 0; |
| 101 virtual void CommitVSyncParameters(base::TimeTicks timebase, | |
| 102 base::TimeDelta interval) = 0; | |
| 103 virtual void SetBeginFrameSource(BeginFrameSource* source) = 0; | 101 virtual void SetBeginFrameSource(BeginFrameSource* source) = 0; |
| 104 virtual void SetEstimatedParentDrawTime(base::TimeDelta draw_time) = 0; | 102 virtual void SetEstimatedParentDrawTime(base::TimeDelta draw_time) = 0; |
| 105 virtual void DidSwapBuffersCompleteOnImplThread() = 0; | 103 virtual void DidSwapBuffersCompleteOnImplThread() = 0; |
| 106 virtual void OnCanDrawStateChanged(bool can_draw) = 0; | 104 virtual void OnCanDrawStateChanged(bool can_draw) = 0; |
| 107 virtual void NotifyReadyToActivate() = 0; | 105 virtual void NotifyReadyToActivate() = 0; |
| 108 virtual void NotifyReadyToDraw() = 0; | 106 virtual void NotifyReadyToDraw() = 0; |
| 109 // Please call these 3 functions through | 107 // Please call these 3 functions through |
| 110 // LayerTreeHostImpl's SetNeedsRedraw(), SetNeedsRedrawRect() and | 108 // LayerTreeHostImpl's SetNeedsRedraw(), SetNeedsRedrawRect() and |
| 111 // SetNeedsOneBeginImplFrame(). | 109 // SetNeedsOneBeginImplFrame(). |
| 112 virtual void SetNeedsRedrawOnImplThread() = 0; | 110 virtual void SetNeedsRedrawOnImplThread() = 0; |
| (...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 360 base::TimeDelta delay) override; | 358 base::TimeDelta delay) override; |
| 361 void SetNeedsAnimateForScrollbarAnimation() override; | 359 void SetNeedsAnimateForScrollbarAnimation() override; |
| 362 void SetNeedsRedrawForScrollbarAnimation() override; | 360 void SetNeedsRedrawForScrollbarAnimation() override; |
| 363 ScrollbarSet ScrollbarsFor(int scroll_layer_id) const override; | 361 ScrollbarSet ScrollbarsFor(int scroll_layer_id) const override; |
| 364 | 362 |
| 365 // VideoBeginFrameSource implementation. | 363 // VideoBeginFrameSource implementation. |
| 366 void AddVideoFrameController(VideoFrameController* controller) override; | 364 void AddVideoFrameController(VideoFrameController* controller) override; |
| 367 void RemoveVideoFrameController(VideoFrameController* controller) override; | 365 void RemoveVideoFrameController(VideoFrameController* controller) override; |
| 368 | 366 |
| 369 // OutputSurfaceClient implementation. | 367 // OutputSurfaceClient implementation. |
| 370 void CommitVSyncParameters(base::TimeTicks timebase, | |
| 371 base::TimeDelta interval) override; | |
| 372 void SetBeginFrameSource(BeginFrameSource* source) override; | 368 void SetBeginFrameSource(BeginFrameSource* source) override; |
| 373 void SetNeedsRedrawRect(const gfx::Rect& rect) override; | 369 void SetNeedsRedrawRect(const gfx::Rect& rect) override; |
| 374 void SetExternalTilePriorityConstraints( | 370 void SetExternalTilePriorityConstraints( |
| 375 const gfx::Rect& viewport_rect, | 371 const gfx::Rect& viewport_rect, |
| 376 const gfx::Transform& transform) override; | 372 const gfx::Transform& transform) override; |
| 377 void DidLoseOutputSurface() override; | 373 void DidLoseOutputSurface() override; |
| 378 void DidSwapBuffersComplete() override; | 374 void DidSwapBuffersComplete() override; |
| 379 void DidReceiveTextureInUseResponses( | 375 void DidReceiveTextureInUseResponses( |
| 380 const gpu::TextureInUseResponses& responses) override; | 376 const gpu::TextureInUseResponses& responses) override; |
| 381 void ReclaimResources(const ReturnedResourceArray& resources) override; | 377 void ReclaimResources(const ReturnedResourceArray& resources) override; |
| (...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 853 | 849 |
| 854 std::unique_ptr<PendingTreeDurationHistogramTimer> | 850 std::unique_ptr<PendingTreeDurationHistogramTimer> |
| 855 pending_tree_duration_timer_; | 851 pending_tree_duration_timer_; |
| 856 | 852 |
| 857 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 853 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
| 858 }; | 854 }; |
| 859 | 855 |
| 860 } // namespace cc | 856 } // namespace cc |
| 861 | 857 |
| 862 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 858 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
| OLD | NEW |