Chromium Code Reviews| 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_H_ | 5 #ifndef CC_RESOURCES_PICTURE_LAYER_TILING_H_ |
| 6 #define CC_RESOURCES_PICTURE_LAYER_TILING_H_ | 6 #define CC_RESOURCES_PICTURE_LAYER_TILING_H_ |
| 7 | 7 |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 52 ~TilingRasterTileIterator(); | 52 ~TilingRasterTileIterator(); |
| 53 | 53 |
| 54 operator bool() const { | 54 operator bool() const { |
| 55 return current_tile_ && TileNeedsRaster(current_tile_); | 55 return current_tile_ && TileNeedsRaster(current_tile_); |
| 56 } | 56 } |
| 57 Tile* operator*() { return current_tile_; } | 57 Tile* operator*() { return current_tile_; } |
| 58 TilePriority::PriorityBin get_type() const { return type_; } | 58 TilePriority::PriorityBin get_type() const { return type_; } |
| 59 | 59 |
| 60 TilingRasterTileIterator& operator++(); | 60 TilingRasterTileIterator& operator++(); |
| 61 | 61 |
| 62 bool HasTilesRequiredForActivation() const; | |
|
reveman
2014/04/24 00:17:34
hm, this returns some state that depend on the pos
vmpstr
2014/04/28 18:50:37
Moved this to a separate patch.
| |
| 63 | |
| 62 gfx::Rect TileBounds() const { | 64 gfx::Rect TileBounds() const { |
| 63 DCHECK(*this); | 65 DCHECK(*this); |
| 64 if (type_ == TilePriority::NOW) { | 66 if (type_ == TilePriority::NOW) { |
| 65 return tiling_->tiling_data_.TileBounds(visible_iterator_.index_x(), | 67 return tiling_->tiling_data_.TileBounds(visible_iterator_.index_x(), |
| 66 visible_iterator_.index_y()); | 68 visible_iterator_.index_y()); |
| 67 } | 69 } |
| 68 return tiling_->tiling_data_.TileBounds(spiral_iterator_.index_x(), | 70 return tiling_->tiling_data_.TileBounds(spiral_iterator_.index_x(), |
| 69 spiral_iterator_.index_y()); | 71 spiral_iterator_.index_y()); |
| 70 } | 72 } |
| 71 | 73 |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 306 | 308 |
| 307 private: | 309 private: |
| 308 DISALLOW_ASSIGN(PictureLayerTiling); | 310 DISALLOW_ASSIGN(PictureLayerTiling); |
| 309 | 311 |
| 310 RectExpansionCache expansion_cache_; | 312 RectExpansionCache expansion_cache_; |
| 311 }; | 313 }; |
| 312 | 314 |
| 313 } // namespace cc | 315 } // namespace cc |
| 314 | 316 |
| 315 #endif // CC_RESOURCES_PICTURE_LAYER_TILING_H_ | 317 #endif // CC_RESOURCES_PICTURE_LAYER_TILING_H_ |
| OLD | NEW |