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 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 // RateLimitClient implementation | 215 // RateLimitClient implementation |
216 virtual void rateLimit() OVERRIDE; | 216 virtual void rateLimit() OVERRIDE; |
217 | 217 |
218 bool bufferedUpdates(); | 218 bool bufferedUpdates(); |
219 bool requestPartialTextureUpdate(); | 219 bool requestPartialTextureUpdate(); |
220 | 220 |
221 void setDeviceScaleFactor(float); | 221 void setDeviceScaleFactor(float); |
222 float deviceScaleFactor() const { return m_deviceScaleFactor; } | 222 float deviceScaleFactor() const { return m_deviceScaleFactor; } |
223 | 223 |
224 void setShowFPSCounter(bool show); | 224 void setShowFPSCounter(bool show); |
225 void setFontAtlas(scoped_ptr<FontAtlas>); | |
226 | 225 |
227 HeadsUpDisplayLayer* hudLayer() const { return m_hudLayer.get(); } | 226 HeadsUpDisplayLayer* hudLayer() const { return m_hudLayer.get(); } |
228 | 227 |
229 Proxy* proxy() const { return m_proxy.get(); } | 228 Proxy* proxy() const { return m_proxy.get(); } |
230 | 229 |
231 protected: | 230 protected: |
232 LayerTreeHost(LayerTreeHostClient*, const LayerTreeSettings&); | 231 LayerTreeHost(LayerTreeHostClient*, const LayerTreeSettings&); |
233 bool initialize(scoped_ptr<Thread> implThread); | 232 bool initialize(scoped_ptr<Thread> implThread); |
234 | 233 |
235 private: | 234 private: |
(...skipping 11 matching lines...) Expand all Loading... |
247 void prioritizeTextures(const LayerList&, OverdrawMetrics&); | 246 void prioritizeTextures(const LayerList&, OverdrawMetrics&); |
248 void setPrioritiesForSurfaces(size_t surfaceMemoryBytes); | 247 void setPrioritiesForSurfaces(size_t surfaceMemoryBytes); |
249 void setPrioritiesForLayers(const LayerList&); | 248 void setPrioritiesForLayers(const LayerList&); |
250 size_t calculateMemoryForRenderSurfaces(const LayerList& updateList); | 249 size_t calculateMemoryForRenderSurfaces(const LayerList& updateList); |
251 | 250 |
252 void animateLayers(base::TimeTicks monotonicTime); | 251 void animateLayers(base::TimeTicks monotonicTime); |
253 bool animateLayersRecursive(Layer* current, base::TimeTicks time); | 252 bool animateLayersRecursive(Layer* current, base::TimeTicks time); |
254 void setAnimationEventsRecursive(const AnimationEventsVector&, Layer*, base:
:Time wallClockTime); | 253 void setAnimationEventsRecursive(const AnimationEventsVector&, Layer*, base:
:Time wallClockTime); |
255 | 254 |
256 void createHUDLayerIfNeeded(); | 255 void createHUDLayerIfNeeded(); |
| 256 void createFontAtlasIfNeeded(); |
257 | 257 |
258 bool m_animating; | 258 bool m_animating; |
259 bool m_needsAnimateLayers; | 259 bool m_needsAnimateLayers; |
260 | 260 |
261 base::CancelableClosure m_prepaintCallback; | 261 base::CancelableClosure m_prepaintCallback; |
262 | 262 |
263 LayerTreeHostClient* m_client; | 263 LayerTreeHostClient* m_client; |
264 scoped_ptr<Proxy> m_proxy; | 264 scoped_ptr<Proxy> m_proxy; |
265 | 265 |
266 int m_commitNumber; | 266 int m_commitNumber; |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
300 size_t m_partialTextureUpdateRequests; | 300 size_t m_partialTextureUpdateRequests; |
301 | 301 |
302 static bool s_needsFilterContext; | 302 static bool s_needsFilterContext; |
303 | 303 |
304 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 304 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
305 }; | 305 }; |
306 | 306 |
307 } // namespace cc | 307 } // namespace cc |
308 | 308 |
309 #endif // CC_LAYER_TREE_HOST_H_ | 309 #endif // CC_LAYER_TREE_HOST_H_ |
OLD | NEW |