Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(101)

Side by Side Diff: cc/tiles/picture_layer_tiling_set.h

Issue 1405883002: cc: Remove the base RasterSource (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge more Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/tiles/picture_layer_tiling.cc ('k') | cc/tiles/picture_layer_tiling_set.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_TILES_PICTURE_LAYER_TILING_SET_H_ 5 #ifndef CC_TILES_PICTURE_LAYER_TILING_SET_H_
6 #define CC_TILES_PICTURE_LAYER_TILING_SET_H_ 6 #define CC_TILES_PICTURE_LAYER_TILING_SET_H_
7 7
8 #include <set> 8 #include <set>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 const PictureLayerTilingClient* client() const { return client_; } 49 const PictureLayerTilingClient* client() const { return client_; }
50 50
51 void CleanUpTilings(float min_acceptable_high_res_scale, 51 void CleanUpTilings(float min_acceptable_high_res_scale,
52 float max_acceptable_high_res_scale, 52 float max_acceptable_high_res_scale,
53 const std::vector<PictureLayerTiling*>& needed_tilings, 53 const std::vector<PictureLayerTiling*>& needed_tilings,
54 PictureLayerTilingSet* twin_set); 54 PictureLayerTilingSet* twin_set);
55 void RemoveNonIdealTilings(); 55 void RemoveNonIdealTilings();
56 56
57 // This function is called on the active tree during activation. 57 // This function is called on the active tree during activation.
58 void UpdateTilingsToCurrentRasterSourceForActivation( 58 void UpdateTilingsToCurrentRasterSourceForActivation(
59 scoped_refptr<RasterSource> raster_source, 59 scoped_refptr<DisplayListRasterSource> raster_source,
60 const PictureLayerTilingSet* pending_twin_set, 60 const PictureLayerTilingSet* pending_twin_set,
61 const Region& layer_invalidation, 61 const Region& layer_invalidation,
62 float minimum_contents_scale, 62 float minimum_contents_scale,
63 float maximum_contents_scale); 63 float maximum_contents_scale);
64 64
65 // This function is called on the sync tree during commit. 65 // This function is called on the sync tree during commit.
66 void UpdateTilingsToCurrentRasterSourceForCommit( 66 void UpdateTilingsToCurrentRasterSourceForCommit(
67 scoped_refptr<RasterSource> raster_source, 67 scoped_refptr<DisplayListRasterSource> raster_source,
68 const Region& layer_invalidation, 68 const Region& layer_invalidation,
69 float minimum_contents_scale, 69 float minimum_contents_scale,
70 float maximum_contents_scale); 70 float maximum_contents_scale);
71 71
72 // This function is called on the sync tree right after commit. 72 // This function is called on the sync tree right after commit.
73 void UpdateRasterSourceDueToLCDChange( 73 void UpdateRasterSourceDueToLCDChange(
74 const scoped_refptr<RasterSource>& raster_source, 74 const scoped_refptr<DisplayListRasterSource>& raster_source,
75 const Region& layer_invalidation); 75 const Region& layer_invalidation);
76 76
77 PictureLayerTiling* AddTiling(float contents_scale, 77 PictureLayerTiling* AddTiling(
78 scoped_refptr<RasterSource> raster_source); 78 float contents_scale,
79 scoped_refptr<DisplayListRasterSource> raster_source);
79 size_t num_tilings() const { return tilings_.size(); } 80 size_t num_tilings() const { return tilings_.size(); }
80 int NumHighResTilings() const; 81 int NumHighResTilings() const;
81 PictureLayerTiling* tiling_at(size_t idx) { return tilings_[idx]; } 82 PictureLayerTiling* tiling_at(size_t idx) { return tilings_[idx]; }
82 const PictureLayerTiling* tiling_at(size_t idx) const { 83 const PictureLayerTiling* tiling_at(size_t idx) const {
83 return tilings_[idx]; 84 return tilings_[idx];
84 } 85 }
85 WhichTree tree() const { return tree_; } 86 WhichTree tree() const { return tree_; }
86 87
87 PictureLayerTiling* FindTilingWithScale(float scale) const; 88 PictureLayerTiling* FindTilingWithScale(float scale) const;
88 PictureLayerTiling* FindTilingWithResolution(TileResolution resolution) const; 89 PictureLayerTiling* FindTilingWithResolution(TileResolution resolution) const;
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 private: 174 private:
174 explicit PictureLayerTilingSet( 175 explicit PictureLayerTilingSet(
175 WhichTree tree, 176 WhichTree tree,
176 PictureLayerTilingClient* client, 177 PictureLayerTilingClient* client,
177 size_t tiling_interest_area_padding, 178 size_t tiling_interest_area_padding,
178 float skewport_target_time_in_seconds, 179 float skewport_target_time_in_seconds,
179 int skewport_extrapolation_limit_in_content_pixels); 180 int skewport_extrapolation_limit_in_content_pixels);
180 181
181 void CopyTilingsAndPropertiesFromPendingTwin( 182 void CopyTilingsAndPropertiesFromPendingTwin(
182 const PictureLayerTilingSet* pending_twin_set, 183 const PictureLayerTilingSet* pending_twin_set,
183 const scoped_refptr<RasterSource>& raster_source, 184 const scoped_refptr<DisplayListRasterSource>& raster_source,
184 const Region& layer_invalidation); 185 const Region& layer_invalidation);
185 186
186 // Remove one tiling. 187 // Remove one tiling.
187 void Remove(PictureLayerTiling* tiling); 188 void Remove(PictureLayerTiling* tiling);
188 void VerifyTilings(const PictureLayerTilingSet* pending_twin_set) const; 189 void VerifyTilings(const PictureLayerTilingSet* pending_twin_set) const;
189 190
190 ScopedPtrVector<PictureLayerTiling> tilings_; 191 ScopedPtrVector<PictureLayerTiling> tilings_;
191 192
192 const size_t tiling_interest_area_padding_; 193 const size_t tiling_interest_area_padding_;
193 const float skewport_target_time_in_seconds_; 194 const float skewport_target_time_in_seconds_;
194 const int skewport_extrapolation_limit_in_content_pixels_; 195 const int skewport_extrapolation_limit_in_content_pixels_;
195 WhichTree tree_; 196 WhichTree tree_;
196 PictureLayerTilingClient* client_; 197 PictureLayerTilingClient* client_;
197 198
198 friend class Iterator; 199 friend class Iterator;
199 DISALLOW_COPY_AND_ASSIGN(PictureLayerTilingSet); 200 DISALLOW_COPY_AND_ASSIGN(PictureLayerTilingSet);
200 }; 201 };
201 202
202 } // namespace cc 203 } // namespace cc
203 204
204 #endif // CC_TILES_PICTURE_LAYER_TILING_SET_H_ 205 #endif // CC_TILES_PICTURE_LAYER_TILING_SET_H_
OLDNEW
« no previous file with comments | « cc/tiles/picture_layer_tiling.cc ('k') | cc/tiles/picture_layer_tiling_set.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698