OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_PICTURE_LAYER_TILING_SET_H_ | 5 #ifndef CC_PICTURE_LAYER_TILING_SET_H_ |
6 #define CC_PICTURE_LAYER_TILING_SET_H_ | 6 #define CC_PICTURE_LAYER_TILING_SET_H_ |
7 | 7 |
8 #include "cc/picture_layer_tiling.h" | 8 #include "cc/picture_layer_tiling.h" |
9 #include "cc/region.h" | 9 #include "cc/region.h" |
10 #include "cc/scoped_ptr_vector.h" | 10 #include "cc/scoped_ptr_vector.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 void CloneFrom(const PictureLayerTilingSet& other); | 21 void CloneFrom(const PictureLayerTilingSet& other); |
22 | 22 |
23 void SetLayerBounds(gfx::Size layer_bounds); | 23 void SetLayerBounds(gfx::Size layer_bounds); |
24 gfx::Size LayerBounds() const; | 24 gfx::Size LayerBounds() const; |
25 | 25 |
26 void Invalidate(const Region& invalidation); | 26 void Invalidate(const Region& invalidation); |
27 | 27 |
28 void AddTiling(float contents_scale, gfx::Size tile_size); | 28 void AddTiling(float contents_scale, gfx::Size tile_size); |
29 size_t num_tilings() const { return tilings_.size(); } | 29 size_t num_tilings() const { return tilings_.size(); } |
30 | 30 |
| 31 void Reset(); |
| 32 |
31 void UpdateTilePriorities(const gfx::Size& device_viewport, | 33 void UpdateTilePriorities(const gfx::Size& device_viewport, |
32 float layer_content_scale_x, | 34 float layer_content_scale_x, |
33 float layer_content_scale_y, | 35 float layer_content_scale_y, |
34 const gfx::Transform& last_screen_transform, | 36 const gfx::Transform& last_screen_transform, |
35 const gfx::Transform& current_screen_transform, | 37 const gfx::Transform& current_screen_transform, |
36 double time_delta); | 38 double time_delta); |
37 | 39 |
38 // For a given rect, iterates through tiles that can fill it. If no | 40 // For a given rect, iterates through tiles that can fill it. If no |
39 // set of tiles with resources can fill the rect, then it will iterate | 41 // set of tiles with resources can fill the rect, then it will iterate |
40 // through null tiles with valid geometry_rect() until the rect is full. | 42 // through null tiles with valid geometry_rect() until the rect is full. |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 PictureLayerTilingClient* client_; | 76 PictureLayerTilingClient* client_; |
75 gfx::Size layer_bounds_; | 77 gfx::Size layer_bounds_; |
76 ScopedPtrVector<PictureLayerTiling> tilings_; | 78 ScopedPtrVector<PictureLayerTiling> tilings_; |
77 | 79 |
78 friend class Iterator; | 80 friend class Iterator; |
79 }; | 81 }; |
80 | 82 |
81 } // namespace cc | 83 } // namespace cc |
82 | 84 |
83 #endif // CC_PICTURE_LAYER_TILING_SET_H_ | 85 #endif // CC_PICTURE_LAYER_TILING_SET_H_ |
OLD | NEW |