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

Unified Diff: cc/trees/layer_tree_host_common_perftest.cc

Issue 1479883002: cc: Fix draw transform computation for non-drawn layers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove LayerImpl::draw_transform() Created 5 years, 1 month 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/trees/layer_tree_host_common_perftest.cc
diff --git a/cc/trees/layer_tree_host_common_perftest.cc b/cc/trees/layer_tree_host_common_perftest.cc
index df1a3a2a2987ec9d092061dd4e27f54da0e4478b..46080f3c32e57ac6c76ccdc6850354c3ac205153 100644
--- a/cc/trees/layer_tree_host_common_perftest.cc
+++ b/cc/trees/layer_tree_host_common_perftest.cc
@@ -109,6 +109,7 @@ class CalcDrawPropsTest : public LayerTreeHostCommonPerfTest {
PropertyTrees property_trees;
bool verify_property_trees = false;
bool use_property_trees = false;
+ active_tree->IncrementRenderSurfaceListIdForTesting();
LayerTreeHostCommon::CalcDrawPropsImplInputs inputs(
active_tree->root_layer(), active_tree->DrawViewportSize(),
host_impl->DrawTransform(), active_tree->device_scale_factor(),
@@ -122,8 +123,8 @@ class CalcDrawPropsTest : public LayerTreeHostCommonPerfTest {
host_impl->settings().layers_always_allowed_lcd_text,
can_render_to_separate_surface,
host_impl->settings().layer_transforms_should_scale_layer_contents,
- verify_property_trees, use_property_trees, &update_list, 0,
- &property_trees);
+ verify_property_trees, use_property_trees, &update_list,
+ active_tree->current_render_surface_list_id(), &property_trees);
LayerTreeHostCommon::CalculateDrawProperties(&inputs);
}
};
@@ -157,9 +158,9 @@ class BspTreePerfTest : public CalcDrawPropsTest {
std::vector<scoped_ptr<DrawPolygon>> polygon_list;
for (LayerImplList::iterator it = base_list.begin(); it != base_list.end();
++it) {
- DrawPolygon* draw_polygon =
- new DrawPolygon(NULL, gfx::RectF(gfx::SizeF((*it)->bounds())),
- (*it)->draw_transform(), polygon_counter++);
+ DrawPolygon* draw_polygon = new DrawPolygon(
+ NULL, gfx::RectF(gfx::SizeF((*it)->bounds())),
+ (*it)->draw_properties().target_space_transform, polygon_counter++);
polygon_list.push_back(scoped_ptr<DrawPolygon>(draw_polygon));
}

Powered by Google App Engine
This is Rietveld 408576698