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_LAYERS_PICTURE_LAYER_IMPL_H_ | 5 #ifndef CC_LAYERS_PICTURE_LAYER_IMPL_H_ |
6 #define CC_LAYERS_PICTURE_LAYER_IMPL_H_ | 6 #define CC_LAYERS_PICTURE_LAYER_IMPL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 virtual bool HasValidTilePriorities() const; | 151 virtual bool HasValidTilePriorities() const; |
152 bool AllTilesRequiredForActivationAreReadyToDraw() const; | 152 bool AllTilesRequiredForActivationAreReadyToDraw() const; |
153 bool AllTilesRequiredForDrawAreReadyToDraw() const; | 153 bool AllTilesRequiredForDrawAreReadyToDraw() const; |
154 | 154 |
155 protected: | 155 protected: |
156 friend class LayerRasterTileIterator; | 156 friend class LayerRasterTileIterator; |
157 using TileRequirementCheck = bool (PictureLayerTiling::*)(const Tile*) const; | 157 using TileRequirementCheck = bool (PictureLayerTiling::*)(const Tile*) const; |
158 | 158 |
159 PictureLayerImpl(LayerTreeImpl* tree_impl, int id); | 159 PictureLayerImpl(LayerTreeImpl* tree_impl, int id); |
160 PictureLayerTiling* AddTiling(float contents_scale); | 160 PictureLayerTiling* AddTiling(float contents_scale); |
161 void RemoveTiling(float contents_scale); | |
162 void RemoveAllTilings(); | 161 void RemoveAllTilings(); |
163 void SyncFromActiveLayer(const PictureLayerImpl* other); | 162 void SyncFromActiveLayer(const PictureLayerImpl* other); |
164 void AddTilingsForRasterScale(); | 163 void AddTilingsForRasterScale(); |
165 void UpdateTilePriorities(const Occlusion& occlusion_in_content_space); | 164 void UpdateTilePriorities(const Occlusion& occlusion_in_content_space); |
166 virtual bool ShouldAdjustRasterScale() const; | 165 virtual bool ShouldAdjustRasterScale() const; |
167 virtual void RecalculateRasterScales(); | 166 virtual void RecalculateRasterScales(); |
168 void CleanUpTilingsOnActiveLayer( | 167 void CleanUpTilingsOnActiveLayer( |
169 std::vector<PictureLayerTiling*> used_tilings); | 168 std::vector<PictureLayerTiling*> used_tilings); |
170 float MinimumContentsScale() const; | 169 float MinimumContentsScale() const; |
171 void ResetRasterScale(); | 170 void ResetRasterScale(); |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
231 // frame that has a valid viewport for prioritizing tiles. | 230 // frame that has a valid viewport for prioritizing tiles. |
232 gfx::Rect visible_rect_for_tile_priority_; | 231 gfx::Rect visible_rect_for_tile_priority_; |
233 | 232 |
234 friend class PictureLayer; | 233 friend class PictureLayer; |
235 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); | 234 DISALLOW_COPY_AND_ASSIGN(PictureLayerImpl); |
236 }; | 235 }; |
237 | 236 |
238 } // namespace cc | 237 } // namespace cc |
239 | 238 |
240 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ | 239 #endif // CC_LAYERS_PICTURE_LAYER_IMPL_H_ |
OLD | NEW |