⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 269772 in webkit


Ignore:
Timestamp:
Nov 13, 2020, 5:12:16 AM (6 years ago)
Author:
magomez@igalia.com
Message:

[GTK][WPE] CSS backdrop overlay corners are not rounded on results.webkit.org
https://bugs.webkit.org/show_bug.cgi?id=215445

Reviewed by Carlos Garcia Campos.

Source/WebCore:

Pass the backdropFiltersRect from CoordinatedGraphicsLayer through Nicosia to TextureMapperLayer. The
latter will use this value to clip when painting the backdrop layer.

Based on a patch created by Carlos Garcia Campos <cgarcia@igalia.com>.

  • platform/graphics/nicosia/NicosiaPlatformLayer.h:

(Nicosia::CompositionLayer::flushState):

  • platform/graphics/texmap/TextureMapperLayer.cpp:

(WebCore::TextureMapperLayer::paintSelfAndChildren):
(WebCore::TextureMapperLayer::setBackdropFiltersRect):

  • platform/graphics/texmap/TextureMapperLayer.h:
  • platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:

(WebCore::CoordinatedGraphicsLayer::setBackdropFilters):
(WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):

Source/WebKit:

Pass the backdropFiltersRect from the state to TextureMapperLayer.

  • Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:

(WebKit::CoordinatedGraphicsScene::updateSceneState):

LayoutTests:

Update expectations for passing tests.

  • platform/glib/TestExpectations:
Location:
trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r269764 r269772  
     12020-11-13  Miguel Gomez  <magomez@igalia.com>
     2
     3        [GTK][WPE] CSS backdrop overlay corners are not rounded on results.webkit.org
     4        https://bugs.webkit.org/show_bug.cgi?id=215445
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        Update expectations for passing tests.
     9
     10        * platform/glib/TestExpectations:
     11
    1122020-11-12  Youenn Fablet  <youenn@apple.com>
    213
  • trunk/LayoutTests/platform/glib/TestExpectations

    r269759 r269772  
    274274webkit.org/b/214259 fast/gradients/conic-gradient-alpha.html [ ImageOnlyFailure ]
    275275
    276 webkit.org/b/169988 css3/filters/backdrop/backdrop-filter-uneven-corner-radii.html [ ImageOnlyFailure ]
    277276webkit.org/b/169988 css3/filters/backdrop/backdrop-filter-with-border-radius-and-reflection-add.html [ ImageOnlyFailure ]
    278277webkit.org/b/169988 css3/filters/backdrop/backdrop-filter-with-border-radius-and-reflection.html [ ImageOnlyFailure ]
    279 webkit.org/b/169988 css3/filters/backdrop/backdrop-filter-with-border-radius-value-change.html [ ImageOnlyFailure ]
    280 webkit.org/b/169988 css3/filters/backdrop/backdrop-filter-with-border-radius.html [ ImageOnlyFailure ]
    281 webkit.org/b/169988 css3/filters/backdrop/effect-hw.html [ ImageOnlyFailure ]
    282278
    283279webkit.org/b/214682 imported/w3c/web-platform-tests/css/cssom/stylesheet-same-origin.sub.html [ Pass Failure ]
  • trunk/Source/WebCore/ChangeLog

    r269770 r269772  
     12020-11-13  Miguel Gomez  <magomez@igalia.com>
     2
     3        [GTK][WPE] CSS backdrop overlay corners are not rounded on results.webkit.org
     4        https://bugs.webkit.org/show_bug.cgi?id=215445
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        Pass the backdropFiltersRect from CoordinatedGraphicsLayer through Nicosia to TextureMapperLayer. The
     9        latter will use this value to clip when painting the backdrop layer.
     10
     11        Based on a patch created by Carlos Garcia Campos  <cgarcia@igalia.com>.
     12
     13        * platform/graphics/nicosia/NicosiaPlatformLayer.h:
     14        (Nicosia::CompositionLayer::flushState):
     15        * platform/graphics/texmap/TextureMapperLayer.cpp:
     16        (WebCore::TextureMapperLayer::paintSelfAndChildren):
     17        (WebCore::TextureMapperLayer::setBackdropFiltersRect):
     18        * platform/graphics/texmap/TextureMapperLayer.h:
     19        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
     20        (WebCore::CoordinatedGraphicsLayer::setBackdropFilters):
     21        (WebCore::CoordinatedGraphicsLayer::flushCompositingStateForThisLayerOnly):
     22
    1232020-11-13  Zalan Bujtas  <zalan@apple.com>
    224
  • trunk/Source/WebCore/platform/graphics/nicosia/NicosiaPlatformLayer.h

    r269579 r269772  
    186186        RefPtr<CompositionLayer> mask;
    187187        RefPtr<CompositionLayer> backdropLayer;
     188        WebCore::FloatRoundedRect backdropFiltersRect;
    188189
    189190        RefPtr<ContentLayer> contentLayer;
     
    253254        if (pending.delta.backdropFiltersChanged)
    254255            staging.backdropLayer = pending.backdropLayer;
     256        if (pending.delta.backdropFiltersRectChanged)
     257            staging.backdropFiltersRect = pending.backdropFiltersRect;
    255258        if (pending.delta.animationsChanged)
    256259            staging.animations = pending.animations;
  • trunk/Source/WebCore/platform/graphics/texmap/TextureMapperLayer.cpp

    r269599 r269772  
    232232        clipTransform.multiply(options.transform);
    233233        clipTransform.multiply(m_layerTransforms.combined);
    234         options.textureMapper.beginClip(clipTransform, FloatRoundedRect(layerRect()));
     234        options.textureMapper.beginClip(clipTransform, m_state.backdropFiltersRect);
    235235        m_state.backdropLayer->paintRecursive(options);
    236236        options.textureMapper.endClip();
     
    562562}
    563563
     564void TextureMapperLayer::setBackdropFiltersRect(const FloatRoundedRect& backdropFiltersRect)
     565{
     566    m_state.backdropFiltersRect = backdropFiltersRect;
     567}
     568
    564569void TextureMapperLayer::setPosition(const FloatPoint& position)
    565570{
  • trunk/Source/WebCore/platform/graphics/texmap/TextureMapperLayer.h

    r269570 r269772  
    6060    void setReplicaLayer(TextureMapperLayer*);
    6161    void setBackdropLayer(TextureMapperLayer*);
     62    void setBackdropFiltersRect(const FloatRoundedRect&);
    6263    void setPosition(const FloatPoint&);
    6364    void setBoundsOrigin(const FloatPoint&);
     
    178179        WeakPtr<TextureMapperLayer> replicaLayer;
    179180        WeakPtr<TextureMapperLayer> backdropLayer;
     181        FloatRoundedRect backdropFiltersRect;
    180182        Color solidColor;
    181183        FilterOperations filters;
  • trunk/Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp

    r269614 r269772  
    531531    } else
    532532        clearBackdropFilters();
     533
    533534    didChangeBackdropFilters();
    534535
     
    956957                }
    957958
     959                if (localDelta.backdropFiltersRectChanged)
     960                    state.backdropFiltersRect = m_backdropFiltersRect;
     961
    958962                if (localDelta.animationsChanged)
    959963                    state.animations = m_animations;
  • trunk/Source/WebKit/ChangeLog

    r269771 r269772  
     12020-11-13  Miguel Gomez  <magomez@igalia.com>
     2
     3        [GTK][WPE] CSS backdrop overlay corners are not rounded on results.webkit.org
     4        https://bugs.webkit.org/show_bug.cgi?id=215445
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        Pass the backdropFiltersRect from the state to TextureMapperLayer.
     9
     10        * Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:
     11        (WebKit::CoordinatedGraphicsScene::updateSceneState):
     12
    1132020-11-13  Kimmo Kinnunen  <kkinnunen@apple.com>
    214
  • trunk/Source/WebKit/Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp

    r268923 r269772  
    307307                        if (layerState.delta.backdropFiltersChanged)
    308308                            layer.setBackdropLayer(layerState.backdropLayer ? &texmapLayer(*layerState.backdropLayer) : nullptr);
     309                        if (layerState.delta.backdropFiltersRectChanged)
     310                            layer.setBackdropFiltersRect(layerState.backdropFiltersRect);
    309311                        if (layerState.delta.animationsChanged)
    310312                            layer.setAnimations(layerState.animations);
Note: See TracChangeset for help on using the changeset viewer.