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 <list> | 8 #include <list> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 virtual scoped_ptr<SwapPromiseMonitor> CreateLatencyInfoSwapPromiseMonitor( | 158 virtual scoped_ptr<SwapPromiseMonitor> CreateLatencyInfoSwapPromiseMonitor( |
159 ui::LatencyInfo* latency) OVERRIDE; | 159 ui::LatencyInfo* latency) OVERRIDE; |
160 | 160 |
161 // TopControlsManagerClient implementation. | 161 // TopControlsManagerClient implementation. |
162 virtual void DidChangeTopControlsPosition() OVERRIDE; | 162 virtual void DidChangeTopControlsPosition() OVERRIDE; |
163 virtual bool HaveRootScrollLayer() const OVERRIDE; | 163 virtual bool HaveRootScrollLayer() const OVERRIDE; |
164 | 164 |
165 struct CC_EXPORT FrameData : public RenderPassSink { | 165 struct CC_EXPORT FrameData : public RenderPassSink { |
166 FrameData(); | 166 FrameData(); |
167 virtual ~FrameData(); | 167 virtual ~FrameData(); |
168 scoped_ptr<base::Value> AsValue() const; | 168 void AsValueInto(base::debug::TracedValue* value) const; |
169 | 169 |
170 std::vector<gfx::Rect> occluding_screen_space_rects; | 170 std::vector<gfx::Rect> occluding_screen_space_rects; |
171 std::vector<gfx::Rect> non_occluding_screen_space_rects; | 171 std::vector<gfx::Rect> non_occluding_screen_space_rects; |
172 RenderPassList render_passes; | 172 RenderPassList render_passes; |
173 RenderPassIdHashMap render_passes_by_id; | 173 RenderPassIdHashMap render_passes_by_id; |
174 const LayerImplList* render_surface_layer_list; | 174 const LayerImplList* render_surface_layer_list; |
175 LayerImplList will_draw_layers; | 175 LayerImplList will_draw_layers; |
176 bool contains_incomplete_tile; | 176 bool contains_incomplete_tile; |
177 bool has_no_damage; | 177 bool has_no_damage; |
178 | 178 |
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
427 | 427 |
428 void UpdateCurrentFrameTime(); | 428 void UpdateCurrentFrameTime(); |
429 void ResetCurrentFrameTimeForNextFrame(); | 429 void ResetCurrentFrameTimeForNextFrame(); |
430 virtual base::TimeTicks CurrentFrameTimeTicks(); | 430 virtual base::TimeTicks CurrentFrameTimeTicks(); |
431 | 431 |
432 // Expected time between two begin impl frame calls. | 432 // Expected time between two begin impl frame calls. |
433 base::TimeDelta begin_impl_frame_interval() const { | 433 base::TimeDelta begin_impl_frame_interval() const { |
434 return begin_impl_frame_interval_; | 434 return begin_impl_frame_interval_; |
435 } | 435 } |
436 | 436 |
437 scoped_ptr<base::Value> AsValue() const { return AsValueWithFrame(NULL); } | 437 void AsValueInto(base::debug::TracedValue* value) const { |
438 scoped_ptr<base::Value> AsValueWithFrame(FrameData* frame) const; | 438 return AsValueWithFrameInto(NULL, value); |
439 scoped_ptr<base::Value> ActivationStateAsValue() const; | 439 } |
| 440 void AsValueWithFrameInto(FrameData* frame, |
| 441 base::debug::TracedValue* value) const; |
| 442 scoped_refptr<base::debug::ConvertableToTraceFormat> AsValue() const; |
| 443 scoped_refptr<base::debug::ConvertableToTraceFormat> AsValueWithFrame( |
| 444 FrameData* frame) const; |
| 445 scoped_refptr<base::debug::ConvertableToTraceFormat> ActivationStateAsValue() |
| 446 const; |
| 447 void ActivationStateAsValueInto(base::debug::TracedValue* value) const; |
440 | 448 |
441 bool page_scale_animation_active() const { return !!page_scale_animation_; } | 449 bool page_scale_animation_active() const { return !!page_scale_animation_; } |
442 | 450 |
443 virtual void CreateUIResource(UIResourceId uid, | 451 virtual void CreateUIResource(UIResourceId uid, |
444 const UIResourceBitmap& bitmap); | 452 const UIResourceBitmap& bitmap); |
445 // Deletes a UI resource. May safely be called more than once. | 453 // Deletes a UI resource. May safely be called more than once. |
446 virtual void DeleteUIResource(UIResourceId uid); | 454 virtual void DeleteUIResource(UIResourceId uid); |
447 void EvictAllUIResources(); | 455 void EvictAllUIResources(); |
448 bool EvictedUIResourcesExist() const; | 456 bool EvictedUIResourcesExist() const; |
449 | 457 |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
711 | 719 |
712 std::vector<PictureLayerImpl*> picture_layers_; | 720 std::vector<PictureLayerImpl*> picture_layers_; |
713 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_; | 721 std::vector<PictureLayerImpl::Pair> picture_layer_pairs_; |
714 | 722 |
715 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); | 723 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); |
716 }; | 724 }; |
717 | 725 |
718 } // namespace cc | 726 } // namespace cc |
719 | 727 |
720 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ | 728 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ |
OLD | NEW |