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

Unified Diff: cc/layer_tree_host_common.cc

Issue 11635037: cc: When the transform's scale is unknown, draw render surfaces at the resolution of the screen. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 0. 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
« no previous file with comments | « no previous file | cc/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_tree_host_common.cc
diff --git a/cc/layer_tree_host_common.cc b/cc/layer_tree_host_common.cc
index b9fc38083f32150ab968b4c6e0e2770216c7a2be..d0a63728b3cd073b31f6640cb9516d66be8edaa5 100644
--- a/cc/layer_tree_host_common.cc
+++ b/cc/layer_tree_host_common.cc
@@ -390,7 +390,7 @@ static inline void updateLayerContentsScale(Layer* layer, const gfx::Transform&
rasterScale = 1;
if (!animatingTransformToScreen && layer->automaticallyComputeRasterScale()) {
- gfx::Vector2dF transformScale = MathUtil::computeTransform2dScaleComponents(combinedTransform);
+ gfx::Vector2dF transformScale = MathUtil::computeTransform2dScaleComponents(combinedTransform, 0.f);
danakj 2012/12/20 23:27:12 Now switch to 0.f so we don't save it when we don'
float combinedScale = std::max(transformScale.x(), transformScale.y());
rasterScale = combinedScale / deviceScaleFactor;
if (!layer->boundsContainPageScale())
@@ -660,7 +660,7 @@ static void calculateDrawPropertiesInternal(LayerType* layer, const gfx::Transfo
gfx::Transform nextHierarchyMatrix = fullHierarchyMatrix;
gfx::Transform sublayerMatrix;
- gfx::Vector2dF renderSurfaceSublayerScale = MathUtil::computeTransform2dScaleComponents(combinedTransform);
+ gfx::Vector2dF renderSurfaceSublayerScale = MathUtil::computeTransform2dScaleComponents(combinedTransform, deviceScaleFactor * pageScaleFactor);
if (subtreeShouldRenderToSeparateSurface(layer, combinedTransform.IsScaleOrTranslation())) {
// Check back-face visibility before continuing with this surface and its subtree
« no previous file with comments | « no previous file | cc/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698