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

Side by Side Diff: cc/picture_layer_tiling_set.h

Issue 11414238: implement the logic to set tile priorities based on current matrix (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: switching to rectF Created 8 years 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 | Annotate | Revision Log
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_PICTURE_LAYER_TILING_SET_H_ 5 #ifndef CC_PICTURE_LAYER_TILING_SET_H_
6 #define CC_PICTURE_LAYER_TILING_SET_H_ 6 #define CC_PICTURE_LAYER_TILING_SET_H_
7 7
8 #include "cc/picture_layer_tiling.h" 8 #include "cc/picture_layer_tiling.h"
9 #include "cc/region.h" 9 #include "cc/region.h"
10 #include "cc/scoped_ptr_vector.h" 10 #include "cc/scoped_ptr_vector.h"
(...skipping 10 matching lines...) Expand all
21 void CloneFrom(const PictureLayerTilingSet& other); 21 void CloneFrom(const PictureLayerTilingSet& other);
22 22
23 void SetLayerBounds(gfx::Size layer_bounds); 23 void SetLayerBounds(gfx::Size layer_bounds);
24 gfx::Size LayerBounds() const; 24 gfx::Size LayerBounds() const;
25 25
26 void Invalidate(const Region& invalidation); 26 void Invalidate(const Region& invalidation);
27 27
28 void AddTiling(float contents_scale, gfx::Size tile_size); 28 void AddTiling(float contents_scale, gfx::Size tile_size);
29 size_t num_tilings() const { return tilings_.size(); } 29 size_t num_tilings() const { return tilings_.size(); }
30 30
31 void UpdateTilePriorities(const gfx::Size& view_port,
32 float layer_content_scaleX,
33 float layer_content_scaleY,
34 const gfx::Transform& last_screen_transform,
35 const gfx::Transform& current_screen_transform,
36 double time_delta);
37
31 // For a given rect, iterates through tiles that can fill it. If no 38 // For a given rect, iterates through tiles that can fill it. If no
32 // set of tiles with resources can fill the rect, then it will iterate 39 // set of tiles with resources can fill the rect, then it will iterate
33 // through null tiles with valid geometry_rect() until the rect is full. 40 // through null tiles with valid geometry_rect() until the rect is full.
34 // If all tiles have resources, the union of all geometry_rects will 41 // If all tiles have resources, the union of all geometry_rects will
35 // exactly fill rect with no overlap. 42 // exactly fill rect with no overlap.
36 class CC_EXPORT Iterator { 43 class CC_EXPORT Iterator {
37 public: 44 public:
38 Iterator(PictureLayerTilingSet* set, float contents_scale, gfx::Rect rect); 45 Iterator(PictureLayerTilingSet* set, float contents_scale, gfx::Rect rect);
39 ~Iterator(); 46 ~Iterator();
40 47
(...skipping 26 matching lines...) Expand all
67 PictureLayerTilingClient* client_; 74 PictureLayerTilingClient* client_;
68 gfx::Size layer_bounds_; 75 gfx::Size layer_bounds_;
69 ScopedPtrVector<PictureLayerTiling> tilings_; 76 ScopedPtrVector<PictureLayerTiling> tilings_;
70 77
71 friend class Iterator; 78 friend class Iterator;
72 }; 79 };
73 80
74 } // namespace cc 81 } // namespace cc
75 82
76 #endif // CC_PICTURE_LAYER_TILING_SET_H_ 83 #endif // CC_PICTURE_LAYER_TILING_SET_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698