https://bugs.webkit.org/show_bug.cgi?id=219136
<rdar://problem/71742605>
Reviewed by Carlos Garcia Campos.
Source/WebCore:
computeOverlapRegions shouldn't include the descendent layer
region for layers with a mask layer. Add a new mode Mask to
ComputeOverlapRegionMode which is like Union mode but doesn't
include descendent layers.
Test: compositing/masks/clip-path-composited-descendent-2.html
* platform/graphics/texmap/TextureMapperLayer.cpp:
(WebCore::TextureMapperLayer::computeOverlapRegions): Skip
children for the Mask mode.
(WebCore::TextureMapperLayer::paintUsingOverlapRegions): Use
ComputeOverlapRegionMode::Mask for a layer with mask layer.
* platform/graphics/texmap/TextureMapperLayer.h (ComputeOverlapRegionMode): Added Mask.
LayoutTests:
* compositing/masks/clip-path-composited-descendent-2-expected.html: Added.
* compositing/masks/clip-path-composited-descendent-2.html: Added.
Canonical link: https://commits.webkit.org/232361@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@270698 268f45cc-cd09-0410-ab3c-d52691b4dbfc