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

Unified Diff: cc/test/fake_tile_manager.cc

Issue 18581004: cc: Remove tile ref counting in tile manager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 7 years, 6 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
« cc/resources/tile_manager.cc ('K') | « cc/test/fake_tile_manager.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_tile_manager.cc
diff --git a/cc/test/fake_tile_manager.cc b/cc/test/fake_tile_manager.cc
index 7afda91f7b9fdc0f0daad9abe5eea86b3a7da4bb..908f42f83216a81f844c2271a7b0d8c7cab9df73 100644
--- a/cc/test/fake_tile_manager.cc
+++ b/cc/test/fake_tile_manager.cc
@@ -39,13 +39,21 @@ FakeTileManager::FakeTileManager(TileManagerClient* client,
resource_provider->best_texture_format()) {}
void FakeTileManager::ReassignMemoryToOOMTilesRequiredForActivation() {
- ReassignGpuMemoryToOOMTilesRequiredForActivation();
+ ReassignGpuMemoryToOOMTilesRequiredForActivation(&tiles_for_raster);
+}
+
+void FakeTileManager::AssignMemoryToTiles() {
+ tiles_for_raster.clear();
+
+ AssignBinsToTiles();
+ SortTiles();
+ AssignGpuMemoryToTiles(&tiles_for_raster);
}
bool FakeTileManager::HasBeenAssignedMemory(Tile* tile) {
- return std::find(tiles_that_need_to_be_rasterized().begin(),
- tiles_that_need_to_be_rasterized().end(),
- tile) != tiles_that_need_to_be_rasterized().end();
+ return std::find(tiles_for_raster.begin(),
+ tiles_for_raster.end(),
+ tile) != tiles_for_raster.end();
}
} // namespace cc
« cc/resources/tile_manager.cc ('K') | « cc/test/fake_tile_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698