| 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_RESOURCES_PICTURE_LAYER_TILING_SET_H_ | 5 #ifndef CC_RESOURCES_PICTURE_LAYER_TILING_SET_H_ |
| 6 #define CC_RESOURCES_PICTURE_LAYER_TILING_SET_H_ | 6 #define CC_RESOURCES_PICTURE_LAYER_TILING_SET_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 // Remove all tiles; keep all tilings. | 105 // Remove all tiles; keep all tilings. |
| 106 void RemoveAllTiles(); | 106 void RemoveAllTiles(); |
| 107 | 107 |
| 108 // Update the rects and priorities for tiles based on the given information. | 108 // Update the rects and priorities for tiles based on the given information. |
| 109 bool UpdateTilePriorities(const gfx::Rect& required_rect_in_layer_space, | 109 bool UpdateTilePriorities(const gfx::Rect& required_rect_in_layer_space, |
| 110 float ideal_contents_scale, | 110 float ideal_contents_scale, |
| 111 double current_frame_time_in_seconds, | 111 double current_frame_time_in_seconds, |
| 112 const Occlusion& occlusion_in_layer_space, | 112 const Occlusion& occlusion_in_layer_space, |
| 113 bool can_require_tiles_for_activation); | 113 bool can_require_tiles_for_activation); |
| 114 | 114 |
| 115 void GetAllTilesForTracing(std::set<const Tile*>* tiles) const; | 115 void GetAllTilesAndPrioritiesForTracing( |
| 116 std::map<const Tile*, TilePriority>* tile_map) const; |
| 116 | 117 |
| 117 // For a given rect, iterates through tiles that can fill it. If no | 118 // For a given rect, iterates through tiles that can fill it. If no |
| 118 // set of tiles with resources can fill the rect, then it will iterate | 119 // set of tiles with resources can fill the rect, then it will iterate |
| 119 // through null tiles with valid geometry_rect() until the rect is full. | 120 // through null tiles with valid geometry_rect() until the rect is full. |
| 120 // If all tiles have resources, the union of all geometry_rects will | 121 // If all tiles have resources, the union of all geometry_rects will |
| 121 // exactly fill rect with no overlap. | 122 // exactly fill rect with no overlap. |
| 122 class CC_EXPORT CoverageIterator { | 123 class CC_EXPORT CoverageIterator { |
| 123 public: | 124 public: |
| 124 CoverageIterator(const PictureLayerTilingSet* set, | 125 CoverageIterator(const PictureLayerTilingSet* set, |
| 125 float contents_scale, | 126 float contents_scale, |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 const int skewport_extrapolation_limit_in_content_pixels_; | 184 const int skewport_extrapolation_limit_in_content_pixels_; |
| 184 PictureLayerTilingClient* client_; | 185 PictureLayerTilingClient* client_; |
| 185 | 186 |
| 186 friend class Iterator; | 187 friend class Iterator; |
| 187 DISALLOW_COPY_AND_ASSIGN(PictureLayerTilingSet); | 188 DISALLOW_COPY_AND_ASSIGN(PictureLayerTilingSet); |
| 188 }; | 189 }; |
| 189 | 190 |
| 190 } // namespace cc | 191 } // namespace cc |
| 191 | 192 |
| 192 #endif // CC_RESOURCES_PICTURE_LAYER_TILING_SET_H_ | 193 #endif // CC_RESOURCES_PICTURE_LAYER_TILING_SET_H_ |
| OLD | NEW |