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

Unified Diff: cc/tile_manager.h

Issue 11568027: cc: Add TileManager interface that allows LTHI to determine when to activate pending tree. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Determine bin for each tree. 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 side-by-side diff with in-line comments
Download patch
Index: cc/tile_manager.h
diff --git a/cc/tile_manager.h b/cc/tile_manager.h
index d80e2f1a0b1860441c47e99a947c139821a788a8..b479e9496cc930fb43626023267a09db3ea6dc47 100644
--- a/cc/tile_manager.h
+++ b/cc/tile_manager.h
@@ -59,7 +59,9 @@ class CC_EXPORT ManagedTileState {
std::list<skia::LazyPixelRef*> pending_pixel_refs;
// Ephemeral state, valid only during Manage.
- TileManagerBin bin;
+ TileManagerBin bin[NUM_TREES];
+ // Bin used to determine raster priority.
+ TileManagerBin raster_bin;
TileResolution resolution;
float time_to_needed_in_seconds;
};
@@ -81,7 +83,10 @@ class CC_EXPORT TileManager {
void ManageTiles();
void CheckForCompletedSetPixels();
- void renderingStats(RenderingStats* stats);
+ void GetRenderingStats(RenderingStats* stats);
+
+ int GetTilesInBinCount(TileManagerBin bin, WhichTree tree);
+ int GetDrawableTilesInBinCount(TileManagerBin bin, WhichTree tree);
protected:
// Methods called by Tile
@@ -91,6 +96,7 @@ class CC_EXPORT TileManager {
void WillModifyTilePriority(Tile*, WhichTree, const TilePriority& new_priority);
private:
+ void ResetBinCounts();
void AssignGpuMemoryToTiles();
void FreeResourcesForTile(Tile*);
void ScheduleManageTiles();
@@ -116,6 +122,9 @@ class CC_EXPORT TileManager {
GlobalStateThatImpactsTilePriority global_state_;
+ int tiles_in_bin_count_[NUM_BINS][NUM_TREES];
+ int drawable_tiles_in_bin_count_[NUM_BINS][NUM_TREES];
+
typedef std::vector<Tile*> TileVector;
TileVector tiles_;
TileVector tiles_that_need_to_be_rasterized_;
« no previous file with comments | « cc/layer_tree_host_impl.cc ('k') | cc/tile_manager.cc » ('j') | cc/tile_manager.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698