Chromium Code Reviews| Index: cc/trees/layer_tree_host_common.cc |
| diff --git a/cc/trees/layer_tree_host_common.cc b/cc/trees/layer_tree_host_common.cc |
| index b8436756fc4762df4194493b3d602e274a8d1ab3..49f86b990cc980cd4d189d23790db776c74eb77b 100644 |
| --- a/cc/trees/layer_tree_host_common.cc |
| +++ b/cc/trees/layer_tree_host_common.cc |
| @@ -576,6 +576,24 @@ static bool SubtreeShouldRenderToSeparateSurface( |
| return true; |
| } |
| + // If the layer has blending. |
| + if (layer->has_blend_mode()) { |
|
shawnsingh
2013/09/25 05:33:53
Can we support blend modes for layers when possibl
rosca
2013/09/25 18:00:00
This is one of the optimizations I was thinking of
|
| + TRACE_EVENT_INSTANT0( |
| + "cc", |
| + "LayerTreeHostCommon::SubtreeShouldRenderToSeparateSurface blending", |
| + TRACE_EVENT_SCOPE_THREAD); |
| + return true; |
| + } |
| + |
| + // If the layer has isolation. |
| + if (layer->is_root_for_isolated_group()) { |
|
enne (OOO)
2013/09/24 18:05:48
Whoa there. According to http://dev.w3.org/fxtf/c
rosca
2013/09/24 21:22:47
We create separate rendering surfaces only for sta
shawnsingh
2013/09/25 05:33:53
Enne@ - I disagree about using setForceRenderSurfa
enne (OOO)
2013/09/26 16:25:13
I think there's sort of two approaches you can tak
rosca
2013/09/27 10:39:06
I added a TODO comment with this improvement in th
enne (OOO)
2013/09/27 17:42:33
Can you file a bug, assign it to yourself, and ref
rosca
2013/09/30 17:28:36
Here is the bug: http://crbug.com/301738. Unfortun
|
| + TRACE_EVENT_INSTANT0( |
| + "cc", |
| + "LayerTreeHostCommon::SubtreeShouldRenderToSeparateSurface isolation", |
| + TRACE_EVENT_SCOPE_THREAD); |
| + return true; |
| + } |
| + |
| // If the layer clips its descendants but it is not axis-aligned with respect |
| // to its parent. |
| bool layer_clips_external_content = |
| @@ -1514,6 +1532,8 @@ static void CalculateDrawPropertiesInternal( |
| layer_draw_properties.screen_space_opacity_is_animating = |
| animating_opacity_to_screen; |
| + render_surface->SetHasBlendMode(layer->has_blend_mode()); |
|
shawnsingh
2013/09/25 05:33:53
FYI, if we do add support for blend modes on layer
rosca
2013/09/25 18:00:00
I removed the has_blend_mode property from RenderS
|
| + |
| render_surface->SetTargetSurfaceTransformsAreAnimating( |
| animating_transform_to_target); |
| render_surface->SetScreenSpaceTransformsAreAnimating( |