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

Unified Diff: cc/picture_layer_tiling_set.h

Issue 11704002: cc: Generate tilings at other scales for impl-side painting (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase, sort() Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/picture_layer_tiling.cc ('k') | cc/picture_layer_tiling_set.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/picture_layer_tiling_set.h
diff --git a/cc/picture_layer_tiling_set.h b/cc/picture_layer_tiling_set.h
index 383884e1de1afca8038c2b1ad4cc3bc6af024c78..72b583ec58f0ef3cc4ac150310e0550a08d88f2d 100644
--- a/cc/picture_layer_tiling_set.h
+++ b/cc/picture_layer_tiling_set.h
@@ -26,13 +26,20 @@ class CC_EXPORT PictureLayerTilingSet {
void SetLayerBounds(gfx::Size layer_bounds);
gfx::Size LayerBounds() const;
- const PictureLayerTiling* AddTiling(
+ PictureLayerTiling* AddTiling(
float contents_scale,
gfx::Size tile_size);
size_t num_tilings() const { return tilings_.size(); }
PictureLayerTiling* tiling_at(size_t idx) { return tilings_[idx]; }
- void Reset();
+ // Remove all tilings.
+ void RemoveAllTilings();
+
+ // Remove one tiling.
+ void Remove(PictureLayerTiling* tiling);
+
+ // Remove all tiles; keep all tilings.
+ void RemoveAllTiles();
void UpdateTilePriorities(
WhichTree tree,
@@ -53,7 +60,8 @@ class CC_EXPORT PictureLayerTilingSet {
Iterator(
const PictureLayerTilingSet* set,
float contents_scale,
- gfx::Rect rect);
+ gfx::Rect content_rect,
+ float ideal_contents_scale);
~Iterator();
// Visible rect (no borders), always in the space of rect,
@@ -70,11 +78,17 @@ class CC_EXPORT PictureLayerTilingSet {
Iterator& operator++();
operator bool() const;
+ PictureLayerTiling* CurrentTiling();
+
private:
+ int NextTiling() const;
+
const PictureLayerTilingSet* set_;
float contents_scale_;
+ float ideal_contents_scale_;
PictureLayerTiling::Iterator tiling_iter_;
int current_tiling_;
+ int ideal_tiling_;
Region current_region_;
Region missing_region_;
« no previous file with comments | « cc/picture_layer_tiling.cc ('k') | cc/picture_layer_tiling_set.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698