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

Side by Side Diff: cc/trees/draw_property_utils.cc

Issue 2245463002: cc : Cache trasnforms to target even when target is a descendant (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: test Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | cc/trees/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/trees/draw_property_utils.h" 5 #include "cc/trees/draw_property_utils.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 VerifySurfaceContentsScalesMatch(clip_node->target_effect_id, 123 VerifySurfaceContentsScalesMatch(clip_node->target_effect_id,
124 clip_node->target_transform_id, 124 clip_node->target_transform_id,
125 effect_tree, transform_tree); 125 effect_tree, transform_tree);
126 #endif 126 #endif
127 *clip_rect_in_target_space = MathUtil::MapClippedRect( 127 *clip_rect_in_target_space = MathUtil::MapClippedRect(
128 clip_to_target, clip_node->clip_in_target_space); 128 clip_to_target, clip_node->clip_in_target_space);
129 } else { 129 } else {
130 return false; 130 return false;
131 } 131 }
132 } else { 132 } else {
133 if (property_trees->ComputeTransformToTarget(clip_node->target_transform_id, 133 if (property_trees->ComputeTransformFromTarget(
134 target_effect_node->id, 134 target_node_id, clip_node->target_effect_id, &clip_to_target)) {
135 &clip_to_target)) {
136 *clip_rect_in_target_space = MathUtil::ProjectClippedRect( 135 *clip_rect_in_target_space = MathUtil::ProjectClippedRect(
137 clip_to_target, clip_node->clip_in_target_space); 136 clip_to_target, clip_node->clip_in_target_space);
138 } else { 137 } else {
139 return false; 138 return false;
140 } 139 }
141 } 140 }
142 return true; 141 return true;
143 } 142 }
144 143
145 struct ConditionalClip { 144 struct ConditionalClip {
(...skipping 1450 matching lines...) Expand 10 before | Expand all | Expand 10 after
1596 void UpdateElasticOverscroll(PropertyTrees* property_trees, 1595 void UpdateElasticOverscroll(PropertyTrees* property_trees,
1597 const Layer* overscroll_elasticity_layer, 1596 const Layer* overscroll_elasticity_layer,
1598 const gfx::Vector2dF& elastic_overscroll) { 1597 const gfx::Vector2dF& elastic_overscroll) {
1599 UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer, 1598 UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer,
1600 elastic_overscroll); 1599 elastic_overscroll);
1601 } 1600 }
1602 1601
1603 } // namespace draw_property_utils 1602 } // namespace draw_property_utils
1604 1603
1605 } // namespace cc 1604 } // namespace cc
OLDNEW
« 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