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_LAYER_TREE_HOST_H_ | 5 #ifndef CC_LAYER_TREE_HOST_H_ |
6 #define CC_LAYER_TREE_HOST_H_ | 6 #define CC_LAYER_TREE_HOST_H_ |
7 | 7 |
8 #include <limits> | 8 #include <limits> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 // Returns true if any LayerTreeHost is alive. | 82 // Returns true if any LayerTreeHost is alive. |
83 static bool anyLayerTreeHostInstanceExists(); | 83 static bool anyLayerTreeHostInstanceExists(); |
84 | 84 |
85 static bool needsFilterContext() { return s_needsFilterContext; } | 85 static bool needsFilterContext() { return s_needsFilterContext; } |
86 static void setNeedsFilterContext(bool needsFilterContext) { s_needsFilterCo
ntext = needsFilterContext; } | 86 static void setNeedsFilterContext(bool needsFilterContext) { s_needsFilterCo
ntext = needsFilterContext; } |
87 bool needsSharedContext() const { return needsFilterContext() || settings().
acceleratePainting; } | 87 bool needsSharedContext() const { return needsFilterContext() || settings().
acceleratePainting; } |
88 | 88 |
89 // LayerTreeHost interface to Proxy. | 89 // LayerTreeHost interface to Proxy. |
90 void willBeginFrame() { m_client->willBeginFrame(); } | 90 void willBeginFrame() { m_client->willBeginFrame(); } |
91 void didBeginFrame(); | 91 void didBeginFrame(); |
92 void updateAnimations(base::TimeTicks monotonicFrameBeginTime); | 92 void updateAnimations(base::TimeTicks monotonicFrameBeginTime, base::Time wa
llClockTime); |
93 void didStopFlinging(); | 93 void didStopFlinging(); |
94 void layout(); | 94 void layout(); |
95 void beginCommitOnImplThread(LayerTreeHostImpl*); | 95 void beginCommitOnImplThread(LayerTreeHostImpl*); |
96 void finishCommitOnImplThread(LayerTreeHostImpl*); | 96 void finishCommitOnImplThread(LayerTreeHostImpl*); |
97 void willCommit(); | 97 void willCommit(); |
98 void commitComplete(); | 98 void commitComplete(); |
99 scoped_ptr<OutputSurface> createOutputSurface(); | 99 scoped_ptr<OutputSurface> createOutputSurface(); |
100 scoped_ptr<InputHandler> createInputHandler(); | 100 scoped_ptr<InputHandler> createInputHandler(); |
101 virtual scoped_ptr<LayerTreeHostImpl> createLayerTreeHostImpl(LayerTreeHostI
mplClient*); | 101 virtual scoped_ptr<LayerTreeHostImpl> createLayerTreeHostImpl(LayerTreeHostI
mplClient*); |
102 void didLoseOutputSurface(); | 102 void didLoseOutputSurface(); |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
219 bool paintMasksForRenderSurface(Layer*, ResourceUpdateQueue&); | 219 bool paintMasksForRenderSurface(Layer*, ResourceUpdateQueue&); |
220 | 220 |
221 void updateLayers(Layer*, ResourceUpdateQueue&); | 221 void updateLayers(Layer*, ResourceUpdateQueue&); |
222 void triggerPrepaint(); | 222 void triggerPrepaint(); |
223 | 223 |
224 void prioritizeTextures(const LayerList&, OverdrawMetrics&); | 224 void prioritizeTextures(const LayerList&, OverdrawMetrics&); |
225 void setPrioritiesForSurfaces(size_t surfaceMemoryBytes); | 225 void setPrioritiesForSurfaces(size_t surfaceMemoryBytes); |
226 void setPrioritiesForLayers(const LayerList&); | 226 void setPrioritiesForLayers(const LayerList&); |
227 size_t calculateMemoryForRenderSurfaces(const LayerList& updateList); | 227 size_t calculateMemoryForRenderSurfaces(const LayerList& updateList); |
228 | 228 |
229 void animateLayers(base::TimeTicks monotonicTime); | 229 void animateLayers(base::TimeTicks monotonicTime, base::Time wallClockTime); |
230 bool animateLayersRecursive(Layer* current, base::TimeTicks time); | 230 bool animateLayersRecursive(Layer* current, base::TimeTicks time); |
231 void setAnimationEventsRecursive(const AnimationEventsVector&, Layer*, base:
:Time wallClockTime); | 231 void setAnimationEventsRecursive(const AnimationEventsVector&, Layer*, base:
:Time wallClockTime); |
232 | 232 |
233 void setNeedsDisplayOnAllLayersRecursive(Layer* layer); | 233 void setNeedsDisplayOnAllLayersRecursive(Layer* layer); |
234 | 234 |
235 bool m_animating; | 235 bool m_animating; |
236 bool m_needsFullTreeSync; | 236 bool m_needsFullTreeSync; |
237 | 237 |
238 base::CancelableClosure m_prepaintCallback; | 238 base::CancelableClosure m_prepaintCallback; |
239 | 239 |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 scoped_ptr<AnimationRegistrar> m_animationRegistrar; | 279 scoped_ptr<AnimationRegistrar> m_animationRegistrar; |
280 | 280 |
281 static bool s_needsFilterContext; | 281 static bool s_needsFilterContext; |
282 | 282 |
283 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 283 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
284 }; | 284 }; |
285 | 285 |
286 } // namespace cc | 286 } // namespace cc |
287 | 287 |
288 #endif // CC_LAYER_TREE_HOST_H_ | 288 #endif // CC_LAYER_TREE_HOST_H_ |
OLD | NEW |