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" |
11 #include "base/cancelable_callback.h" | 11 #include "base/cancelable_callback.h" |
12 #include "base/hash_tables.h" | 12 #include "base/hash_tables.h" |
13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
15 #include "base/time.h" | 15 #include "base/time.h" |
16 #include "cc/animation_events.h" | 16 #include "cc/animation_events.h" |
17 #include "cc/cc_export.h" | 17 #include "cc/cc_export.h" |
18 #include "cc/layer_tree_host_client.h" | 18 #include "cc/layer_tree_host_client.h" |
19 #include "cc/layer_tree_host_common.h" | 19 #include "cc/layer_tree_host_common.h" |
20 #include "cc/layer_tree_settings.h" | 20 #include "cc/layer_tree_settings.h" |
21 #include "cc/occlusion_tracker.h" | 21 #include "cc/occlusion_tracker.h" |
22 #include "cc/output_surface.h" | 22 #include "cc/output_surface.h" |
| 23 #include "cc/picture_pile_impl.h" |
23 #include "cc/prioritized_resource_manager.h" | 24 #include "cc/prioritized_resource_manager.h" |
24 #include "cc/proxy.h" | 25 #include "cc/proxy.h" |
25 #include "cc/rate_limiter.h" | 26 #include "cc/rate_limiter.h" |
26 #include "cc/rendering_stats.h" | 27 #include "cc/rendering_stats.h" |
27 #include "cc/scoped_ptr_vector.h" | 28 #include "cc/scoped_ptr_vector.h" |
28 #include "third_party/skia/include/core/SkColor.h" | 29 #include "third_party/skia/include/core/SkColor.h" |
29 #include "ui/gfx/rect.h" | 30 #include "ui/gfx/rect.h" |
30 | 31 |
31 #if defined(COMPILER_GCC) | 32 #if defined(COMPILER_GCC) |
32 namespace BASE_HASH_NAMESPACE { | 33 namespace BASE_HASH_NAMESPACE { |
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 | 195 |
195 void setDeviceScaleFactor(float); | 196 void setDeviceScaleFactor(float); |
196 float deviceScaleFactor() const { return m_deviceScaleFactor; } | 197 float deviceScaleFactor() const { return m_deviceScaleFactor; } |
197 | 198 |
198 HeadsUpDisplayLayer* hudLayer() const { return m_hudLayer.get(); } | 199 HeadsUpDisplayLayer* hudLayer() const { return m_hudLayer.get(); } |
199 | 200 |
200 Proxy* proxy() const { return m_proxy.get(); } | 201 Proxy* proxy() const { return m_proxy.get(); } |
201 | 202 |
202 AnimationRegistrar* animationRegistrar() const { return m_animationRegistrar
.get(); } | 203 AnimationRegistrar* animationRegistrar() const { return m_animationRegistrar
.get(); } |
203 | 204 |
| 205 scoped_refptr<PicturePileImpl> capturePicturePile(); |
| 206 |
204 protected: | 207 protected: |
205 LayerTreeHost(LayerTreeHostClient*, const LayerTreeSettings&); | 208 LayerTreeHost(LayerTreeHostClient*, const LayerTreeSettings&); |
206 bool initialize(scoped_ptr<Thread> implThread); | 209 bool initialize(scoped_ptr<Thread> implThread); |
207 bool initializeForTesting(scoped_ptr<Proxy> proxyForTesting); | 210 bool initializeForTesting(scoped_ptr<Proxy> proxyForTesting); |
208 | 211 |
209 private: | 212 private: |
210 typedef std::vector<scoped_refptr<Layer> > LayerList; | 213 typedef std::vector<scoped_refptr<Layer> > LayerList; |
211 | 214 |
212 bool initializeProxy(scoped_ptr<Proxy> proxy); | 215 bool initializeProxy(scoped_ptr<Proxy> proxy); |
213 void initializeRenderer(); | 216 void initializeRenderer(); |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
278 scoped_ptr<AnimationRegistrar> m_animationRegistrar; | 281 scoped_ptr<AnimationRegistrar> m_animationRegistrar; |
279 | 282 |
280 static bool s_needsFilterContext; | 283 static bool s_needsFilterContext; |
281 | 284 |
282 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); | 285 DISALLOW_COPY_AND_ASSIGN(LayerTreeHost); |
283 }; | 286 }; |
284 | 287 |
285 } // namespace cc | 288 } // namespace cc |
286 | 289 |
287 #endif // CC_LAYER_TREE_HOST_H_ | 290 #endif // CC_LAYER_TREE_HOST_H_ |
OLD | NEW |