cc :: Layer backface visibility determination without layer tree hierarchy
This CL
* adds bools use_local_transform_for_backface_visibility
and should_check_backface_visibility to Layer and
LayerImpl.
* does backface visibility computation only when
needed (using the bools and transform tree)
BUG=581939
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1652263004
Cr-Commit-Position: refs/heads/master@{#373574}
diff --git a/cc/layers/layer_impl.cc b/cc/layers/layer_impl.cc
index 708c8d2..173237a 100644
--- a/cc/layers/layer_impl.cc
+++ b/cc/layers/layer_impl.cc
@@ -71,6 +71,8 @@
contents_opaque_(false),
is_root_for_isolated_group_(false),
use_parent_backface_visibility_(false),
+ use_local_transform_for_backface_visibility_(false),
+ should_check_backface_visibility_(false),
draws_content_(false),
hide_layer_and_subtree_(false),
transform_is_invertible_(true),
@@ -628,6 +630,9 @@
should_flatten_transform_from_property_tree_);
layer->set_draw_blend_mode(draw_blend_mode_);
layer->SetUseParentBackfaceVisibility(use_parent_backface_visibility_);
+ layer->SetUseLocalTransformForBackfaceVisibility(
+ use_local_transform_for_backface_visibility_);
+ layer->SetShouldCheckBackfaceVisibility(should_check_backface_visibility_);
layer->SetTransformAndInvertibility(transform_, transform_is_invertible_);
layer->SetScrollClipLayer(scroll_clip_layer_id_);