Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(61)

Side by Side Diff: cc/trees/layer_tree_host_impl.h

Issue 221833009: cc: Move scheduling logic out of OutputSurface (Closed) Base URL: http://git.chromium.org/chromium/src.git@swapAck2Sched11
Patch Set: Add OutputSurface::SetNeedsRedrawRect back Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 class TopControlsManager; 56 class TopControlsManager;
57 class UIResourceBitmap; 57 class UIResourceBitmap;
58 class UIResourceRequest; 58 class UIResourceRequest;
59 struct RendererCapabilitiesImpl; 59 struct RendererCapabilitiesImpl;
60 60
61 // LayerTreeHost->Proxy callback interface. 61 // LayerTreeHost->Proxy callback interface.
62 class LayerTreeHostImplClient { 62 class LayerTreeHostImplClient {
63 public: 63 public:
64 virtual void UpdateRendererCapabilitiesOnImplThread() = 0; 64 virtual void UpdateRendererCapabilitiesOnImplThread() = 0;
65 virtual void DidLoseOutputSurfaceOnImplThread() = 0; 65 virtual void DidLoseOutputSurfaceOnImplThread() = 0;
66 virtual void CommitVSyncParameters(base::TimeTicks timebase,
67 base::TimeDelta interval) = 0;
68 virtual void SetEstimatedParentDrawTime(base::TimeDelta draw_time) = 0;
66 virtual void SetMaxSwapsPendingOnImplThread(int max) = 0; 69 virtual void SetMaxSwapsPendingOnImplThread(int max) = 0;
67 virtual void DidSwapBuffersOnImplThread() = 0; 70 virtual void DidSwapBuffersOnImplThread() = 0;
68 virtual void DidSwapBuffersCompleteOnImplThread() = 0; 71 virtual void DidSwapBuffersCompleteOnImplThread() = 0;
69 virtual void BeginFrame(const BeginFrameArgs& args) = 0; 72 virtual void BeginFrame(const BeginFrameArgs& args) = 0;
70 virtual void OnCanDrawStateChanged(bool can_draw) = 0; 73 virtual void OnCanDrawStateChanged(bool can_draw) = 0;
71 virtual void NotifyReadyToActivate() = 0; 74 virtual void NotifyReadyToActivate() = 0;
72 // Please call these 2 functions through 75 // Please call these 2 functions through
73 // LayerTreeHostImpl's SetNeedsRedraw() and SetNeedsRedrawRect(). 76 // LayerTreeHostImpl's SetNeedsRedraw() and SetNeedsRedrawRect().
74 virtual void SetNeedsRedrawOnImplThread() = 0; 77 virtual void SetNeedsRedrawOnImplThread() = 0;
75 virtual void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) = 0; 78 virtual void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) = 0;
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 // RendererClient implementation. 221 // RendererClient implementation.
219 virtual void SetFullRootLayerDamage() OVERRIDE; 222 virtual void SetFullRootLayerDamage() OVERRIDE;
220 223
221 // TileManagerClient implementation. 224 // TileManagerClient implementation.
222 virtual void NotifyReadyToActivate() OVERRIDE; 225 virtual void NotifyReadyToActivate() OVERRIDE;
223 226
224 // OutputSurfaceClient implementation. 227 // OutputSurfaceClient implementation.
225 virtual bool DeferredInitialize( 228 virtual bool DeferredInitialize(
226 scoped_refptr<ContextProvider> offscreen_context_provider) OVERRIDE; 229 scoped_refptr<ContextProvider> offscreen_context_provider) OVERRIDE;
227 virtual void ReleaseGL() OVERRIDE; 230 virtual void ReleaseGL() OVERRIDE;
231 virtual void CommitVSyncParameters(base::TimeTicks timebase,
232 base::TimeDelta interval) OVERRIDE;
228 virtual void SetNeedsRedrawRect(const gfx::Rect& rect) OVERRIDE; 233 virtual void SetNeedsRedrawRect(const gfx::Rect& rect) OVERRIDE;
229 virtual void BeginFrame(const BeginFrameArgs& args) OVERRIDE; 234 virtual void BeginFrame(const BeginFrameArgs& args) OVERRIDE;
230 virtual void SetExternalDrawConstraints( 235 virtual void SetExternalDrawConstraints(
231 const gfx::Transform& transform, 236 const gfx::Transform& transform,
232 const gfx::Rect& viewport, 237 const gfx::Rect& viewport,
233 const gfx::Rect& clip, 238 const gfx::Rect& clip,
234 bool valid_for_tile_management) OVERRIDE; 239 bool valid_for_tile_management) OVERRIDE;
235 virtual void DidLoseOutputSurface() OVERRIDE; 240 virtual void DidLoseOutputSurface() OVERRIDE;
236 virtual void DidSwapBuffers() OVERRIDE; 241 virtual void DidSwapBuffers() OVERRIDE;
237 virtual void DidSwapBuffersComplete() OVERRIDE; 242 virtual void DidSwapBuffersComplete() OVERRIDE;
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
655 int id_; 660 int id_;
656 661
657 std::set<SwapPromiseMonitor*> swap_promise_monitor_; 662 std::set<SwapPromiseMonitor*> swap_promise_monitor_;
658 663
659 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); 664 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl);
660 }; 665 };
661 666
662 } // namespace cc 667 } // namespace cc
663 668
664 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ 669 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698