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

Unified Diff: cc/layers/tiled_layer_impl.cc

Issue 576173003: cc: Move UnoccludedContentRect to Occlusion. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
Index: cc/layers/tiled_layer_impl.cc
diff --git a/cc/layers/tiled_layer_impl.cc b/cc/layers/tiled_layer_impl.cc
index 05ead4700fb33affb7e330423be64dfb3dc1942c..f7f97927d7ddcd549f1905d0a155e790bc7b0876 100644
--- a/cc/layers/tiled_layer_impl.cc
+++ b/cc/layers/tiled_layer_impl.cc
@@ -204,6 +204,8 @@ void TiledLayerImpl::AppendQuads(
if (skips_draw_)
return;
+ Occlusion occlusion =
+ occlusion_tracker.GetCurrentOcclusionForLayer(draw_transform());
for (int j = top; j <= bottom; ++j) {
for (int i = left; i <= right; ++i) {
DrawableTile* tile = TileAt(i, j);
@@ -216,7 +218,7 @@ void TiledLayerImpl::AppendQuads(
continue;
gfx::Rect visible_tile_rect =
- occlusion_tracker.UnoccludedContentRect(tile_rect, draw_transform());
+ occlusion.GetUnoccludedContentRect(tile_rect);
if (visible_tile_rect.IsEmpty())
continue;

Powered by Google App Engine
This is Rietveld 408576698