Chromium Code Reviews| Index: cc/tile_priority.h |
| diff --git a/cc/tile_priority.h b/cc/tile_priority.h |
| index 7672a38dcd64ad4d21e16a25271b189a771b505b..d037657193b22c8032e8cf2ab6c5da09cde08bfc 100644 |
| --- a/cc/tile_priority.h |
| +++ b/cc/tile_priority.h |
| @@ -10,9 +10,12 @@ |
| #include "base/memory/ref_counted.h" |
| #include "base/memory/scoped_ptr.h" |
| #include "cc/picture_pile.h" |
| +#include "ui/gfx/quad_f.h" |
| #include "ui/gfx/rect.h" |
| #include "ui/gfx/size.h" |
| +#define TRACK_TILE_SCREEN_SPACE_QUADS 1 |
| + |
| namespace base { |
| class Value; |
| } |
| @@ -35,6 +38,8 @@ enum TileResolution { |
| HIGH_RESOLUTION = 1, |
| NON_IDEAL_RESOLUTION = 2, |
| }; |
| +scoped_ptr<base::Value> TileResolutionAsValue( |
| + TileResolution resolution); |
| struct CC_EXPORT TilePriority { |
| TilePriority() |
| @@ -89,6 +94,14 @@ struct CC_EXPORT TilePriority { |
| pending.distance_to_visible_in_pixels); |
| } |
| +#ifdef TRACK_TILE_SCREEN_SPACE_QUADS |
|
whunt
2013/02/01 21:09:33
same question on #if defined
|
| + void set_current_screen_quad(const gfx::QuadF& q) { current_screen_quad = q; } |
| +#else |
| + void set_current_screen_quad(const gfx::QuadF& current_screen_quad) {} |
| +#endif |
| + |
| + scoped_ptr<base::Value> AsValue() const; |
| + |
| static const double kMaxTimeToVisibleInSeconds; |
| static const double kMaxDistanceInContentSpace; |
| @@ -107,6 +120,12 @@ struct CC_EXPORT TilePriority { |
| TileResolution resolution; |
| float time_to_visible_in_seconds; |
| float distance_to_visible_in_pixels; |
| + |
| +private: |
| +// TODO(nduca): How do we make this suck minimally? |
| +#if TRACK_TILE_SCREEN_SPACE_QUADS |
| + gfx::QuadF current_screen_quad; |
| +#endif |
| }; |
| enum TileMemoryLimitPolicy { |