Changeset 245147 in webkit


Ignore:
Timestamp:
May 9, 2019 11:26:24 AM (5 years ago)
Author:
Simon Fraser
Message:

fast/hidpi/video-controls-in-hidpi.html sometimes asserts in WK1
https://bugs.webkit.org/show_bug.cgi?id=197695

Reviewed by Zalan Bujtas.

With the backing-sharing changes that landed in r245058, some WebKit1 tests with media controls asserted in
RenderLayerBacking::computeParentGraphicsLayerRect() because a layer would have a m_ancestorClippingLayer,
but backgroundClipRect() would return an infinite rect.

This happened when a layer tree change caused the layer's compositing ancestor to no longer isolate
composited blending (which affects the behavior of RenderLayerCompositor:clippedByAncestor()), but we failed
to mark its composited children as needing the configuration update which would eliminate their m_ancestorClippingLayers.

The fix is to call setChildrenNeedCompositingGeometryUpdate() when isolatesCompositedBlending changes. We don't haev
setChildrenNeedCompositingConfigurationUpdate(), but setChildrenNeedCompositingGeometryUpdate() has the desired side-effect.

I was unable to make a standalone test case for this, but the code is exercised by media control tests.

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::computeCompositingRequirements):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r245142 r245147  
     12019-05-09  Simon Fraser  <simon.fraser@apple.com>
     2
     3        fast/hidpi/video-controls-in-hidpi.html sometimes asserts in WK1
     4        https://bugs.webkit.org/show_bug.cgi?id=197695
     5
     6        Reviewed by Zalan Bujtas.
     7
     8        With the backing-sharing changes that landed in r245058, some WebKit1 tests with media controls asserted in
     9        RenderLayerBacking::computeParentGraphicsLayerRect() because a layer would have a m_ancestorClippingLayer,
     10        but backgroundClipRect() would return an infinite rect.
     11       
     12        This happened when a layer tree change caused the layer's compositing ancestor to no longer isolate
     13        composited blending (which affects the behavior of RenderLayerCompositor:clippedByAncestor()), but we failed
     14        to mark its composited children as needing the configuration update which would eliminate their m_ancestorClippingLayers.
     15       
     16        The fix is to call setChildrenNeedCompositingGeometryUpdate() when isolatesCompositedBlending changes. We don't haev
     17        setChildrenNeedCompositingConfigurationUpdate(), but setChildrenNeedCompositingGeometryUpdate() has the desired side-effect.
     18
     19        I was unable to make a standalone test case for this, but the code is exercised by media control tests.
     20
     21        * rendering/RenderLayerCompositor.cpp:
     22        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
     23
    1242019-05-09  Brent Fulgham  <bfulgham@apple.com>
    225
  • trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp

    r245085 r245147  
    956956
    957957#if ENABLE(CSS_COMPOSITING)
     958    bool isolatedCompositedBlending = layer.isolatesCompositedBlending();
    958959    layer.setHasNotIsolatedCompositedBlendingDescendants(childState.hasNotIsolatedCompositedBlendingDescendants);
     960    if (layer.isolatesCompositedBlending() != isolatedCompositedBlending) {
     961        // isolatedCompositedBlending affects the result of clippedByAncestor().
     962        layer.setChildrenNeedCompositingGeometryUpdate();
     963    }
     964
    959965    ASSERT(!layer.hasNotIsolatedCompositedBlendingDescendants() || layer.hasNotIsolatedBlendingDescendants());
    960966#endif
Note: See TracChangeset for help on using the changeset viewer.