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

Unified Diff: cc/trees/draw_property_utils.cc

Issue 1876903003: cc : Add node and ancestors are animated or invertible to transform tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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/proto/property_tree.proto ('k') | 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 cf058710a7b6b5425ea3b13d6f23e138c4cb3dd8..7ec59a4a7c571c4a438a4cf408f85dd57f550ddb 100644
--- a/cc/trees/draw_property_utils.cc
+++ b/cc/trees/draw_property_utils.cc
@@ -309,12 +309,6 @@ static inline bool TransformToScreenIsKnown(LayerImpl* layer,
}
template <typename LayerType>
-static bool HasInvertibleOrAnimatedTransform(LayerType* layer) {
- return layer->transform_is_invertible() ||
- layer->HasPotentiallyRunningTransformAnimation();
-}
-
-template <typename LayerType>
static bool LayerNeedsUpdateInternal(LayerType* layer,
bool layer_is_drawn,
const TransformTree& tree) {
@@ -420,11 +414,7 @@ static inline bool LayerShouldBeSkipped(Layer* layer,
const EffectNode* effect_node = effect_tree.Node(layer->effect_tree_index());
// If the layer transform is not invertible, it should not be drawn.
- bool has_inherited_invertible_or_animated_transform =
- (transform_node->data.is_invertible &&
- transform_node->data.ancestors_are_invertible) ||
- transform_node->data.to_screen_is_potentially_animated;
- if (!has_inherited_invertible_or_animated_transform)
+ if (!transform_node->data.node_and_ancestors_are_animated_or_invertible)
return true;
// When we need to do a readback/copy of a layer's output, we can not skip
@@ -466,11 +456,7 @@ bool LayerShouldBeSkipped(LayerImpl* layer,
// TODO(ajuma): Correctly process subtrees with singular transform for the
// case where we may animate to a non-singular transform and wish to
// pre-raster.
- bool has_inherited_invertible_or_animated_transform =
- (transform_node->data.is_invertible &&
- transform_node->data.ancestors_are_invertible) ||
- transform_node->data.to_screen_is_potentially_animated;
- if (!has_inherited_invertible_or_animated_transform)
+ if (!transform_node->data.node_and_ancestors_are_animated_or_invertible)
return true;
// When we need to do a readback/copy of a layer's output, we can not skip
« no previous file with comments | « cc/proto/property_tree.proto ('k') | cc/trees/layer_tree_host_common_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698