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

Unified Diff: cc/layers/picture_layer_impl_unittest.cc

Issue 272283003: Revert 261000 "Re-raster GPU-rasterized layers during scale animations" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 6 years, 7 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
« no previous file with comments | « cc/layers/picture_layer_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/picture_layer_impl_unittest.cc
diff --git a/cc/layers/picture_layer_impl_unittest.cc b/cc/layers/picture_layer_impl_unittest.cc
index 4c02e28e302f3d1aade08626b750fc81f7450474..590560f63a186b65d09e107c012992da992237a7 100644
--- a/cc/layers/picture_layer_impl_unittest.cc
+++ b/cc/layers/picture_layer_impl_unittest.cc
@@ -1945,62 +1945,6 @@ TEST_F(PictureLayerImplTest, HighResTilingDuringAnimationForCpuRasterization) {
EXPECT_BOTH_EQ(HighResTiling()->contents_scale(), 4.f);
}
-TEST_F(PictureLayerImplTest, HighResTilingDuringAnimationForGpuRasterization) {
- gfx::Size tile_size(host_impl_.settings().default_tile_size);
- SetupDefaultTrees(tile_size);
- host_impl_.pending_tree()->SetUseGpuRasterization(true);
- host_impl_.active_tree()->SetUseGpuRasterization(true);
- EXPECT_TRUE(pending_layer_->use_gpu_rasterization());
- EXPECT_TRUE(active_layer_->use_gpu_rasterization());
-
- float contents_scale = 1.f;
- float device_scale = 1.f;
- float page_scale = 1.f;
- float maximum_animation_scale = 1.f;
- bool animating_transform = false;
-
- SetContentsScaleOnBothLayers(contents_scale,
- device_scale,
- page_scale,
- maximum_animation_scale,
- animating_transform);
- EXPECT_BOTH_EQ(HighResTiling()->contents_scale(), 1.f);
-
- // Changing contents scale during an animation should cause tiling resolution
- // to change, since we're GPU-rasterizing. The maximum animation scale should
- // not have any effect.
- animating_transform = true;
- contents_scale = 2.f;
- maximum_animation_scale = 4.f;
-
- SetContentsScaleOnBothLayers(contents_scale,
- device_scale,
- page_scale,
- maximum_animation_scale,
- animating_transform);
- EXPECT_BOTH_EQ(HighResTiling()->contents_scale(), 2.f);
-
- // Since we're re-rasterizing during the animation, scales smaller than 1
- // should be respected.
- contents_scale = 0.5f;
- SetContentsScaleOnBothLayers(contents_scale,
- device_scale,
- page_scale,
- maximum_animation_scale,
- animating_transform);
- EXPECT_BOTH_EQ(HighResTiling()->contents_scale(), 0.5f);
-
- // Tiling resolution should also update once we stop animating.
- contents_scale = 4.f;
- animating_transform = false;
- SetContentsScaleOnBothLayers(contents_scale,
- device_scale,
- page_scale,
- maximum_animation_scale,
- animating_transform);
- EXPECT_BOTH_EQ(HighResTiling()->contents_scale(), 4.f);
-}
-
TEST_F(PictureLayerImplTest, LayerRasterTileIterator) {
gfx::Size tile_size(100, 100);
gfx::Size layer_bounds(1000, 1000);
« no previous file with comments | « cc/layers/picture_layer_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698