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

Unified Diff: cc/trees/draw_property_utils.cc

Issue 2712053002: cc : Fix transform calculation bug while calculating clip rects (Closed)
Patch Set: Created 3 years, 10 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 | « no previous file | cc/trees/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/trees/draw_property_utils.cc
diff --git a/cc/trees/draw_property_utils.cc b/cc/trees/draw_property_utils.cc
index 7294e5c598ff36ba0758f4b837206f62f16bca7c..cdb99992d71c9187d35f5ffef95ecdde60d83d15 100644
--- a/cc/trees/draw_property_utils.cc
+++ b/cc/trees/draw_property_utils.cc
@@ -79,6 +79,10 @@ bool ComputeClipRectInTargetSpace(const LayerImpl* layer,
} else {
if (property_trees->ComputeTransformFromTarget(
target_node_id, clip_node->target_effect_id, &clip_to_target)) {
+ const EffectNode* source_node =
+ effect_tree.Node(clip_node->target_effect_id);
+ PostConcatSurfaceContentsScale(target_effect_node, &clip_to_target);
+ ConcatInverseSurfaceContentsScale(source_node, &clip_to_target);
jaydasika 2017/02/24 01:08:39 We do the same thing in ComputeClips when we calcu
*clip_rect_in_target_space =
MathUtil::ProjectClippedRect(clip_to_target, clip_from_clip_node);
} else {
« no previous file with comments | « no previous file | cc/trees/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698