Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 931d2cd37b1190dfff814283b4a8ef10d985dc08
      
https://github.com/WebKit/WebKit/commit/931d2cd37b1190dfff814283b4a8ef10d985dc08
  Author: Georges Basile Stavracas Neto <[email protected]>
  Date:   2024-06-14 (Fri, 14 Jun 2024)

  Changed paths:
    M LayoutTests/css3/filters/effect-drop-shadow-clip-abspos.html
    M 
LayoutTests/imported/blink/css3/filters/effect-drop-shadow-clip-abspos.html
    M 
LayoutTests/imported/w3c/web-platform-tests/css/filter-effects/filters-drop-shadow-002.html
    M Source/WebCore/platform/SourcesSkia.txt
    M Source/WebCore/platform/graphics/filters/FEComponentTransfer.cpp
    M Source/WebCore/platform/graphics/filters/FEDropShadow.cpp
    M Source/WebCore/platform/graphics/filters/FEDropShadow.h
    A 
Source/WebCore/platform/graphics/filters/skia/FEComponentTransferSkiaApplier.cpp
    A 
Source/WebCore/platform/graphics/filters/skia/FEComponentTransferSkiaApplier.h
    A Source/WebCore/platform/graphics/filters/skia/FEDropShadowSkiaApplier.cpp
    A Source/WebCore/platform/graphics/filters/skia/FEDropShadowSkiaApplier.h

  Log Message:
  -----------
  [Skia] Implement FEDropShadow and FEComponentTransfer filters
https://bugs.webkit.org/show_bug.cgi?id=273774

Reviewed by Carlos Garcia Campos.

Skia supports 3 filters already: FEColorMatrix, FEGaussianBlur, and
SourceGraphics. They were added as part of the initial bootstrapping
of Skia filters, mostly as a coding exercise and proof of concept.

CSSFilter.cpp uses two other filters directly: FEComponentTransfer,
and FEDropShadow. Indirectly it uses SVG filters, but that's a rarer
case.

Implement the FEDropShadow and FEComponentTransfer filters in Skia.

The FEDropShadow filter naturally enabled the drop-shadow() CSS filter.
It's implemented using the drop shadow image effect provided by Skia.

The FEComponentTransfer filter is a little less correspondent. It's
used for the CSS invert(), opacity(), contrast(), and brightness()
filters. It's implemented using the color table filter, in a similar
fashion to the software applier.

Adjust tests to allow slightly more fuzziness, as the shadows look
visually identical.

* LayoutTests/css3/filters/effect-drop-shadow-clip-abspos.html:
* LayoutTests/imported/blink/css3/filters/effect-drop-shadow-clip-abspos.html:
* 
LayoutTests/imported/w3c/web-platform-tests/css/filter-effects/filters-drop-shadow-002.html:
* Source/WebCore/platform/SourcesSkia.txt:
* Source/WebCore/platform/graphics/filters/FEComponentTransfer.cpp:
(WebCore::FEComponentTransfer::supportedFilterRenderingModes const):
(WebCore::FEComponentTransfer::createAcceleratedApplier const):
(WebCore::FEComponentTransfer::createSoftwareApplier const):
* Source/WebCore/platform/graphics/filters/FEDropShadow.cpp:
(WebCore::FEDropShadow::supportedFilterRenderingModes const):
(WebCore::FEDropShadow::createAcceleratedApplier const):
(WebCore::FEDropShadow::createSoftwareApplier const):
* Source/WebCore/platform/graphics/filters/FEDropShadow.h:
* 
Source/WebCore/platform/graphics/filters/skia/FEComponentTransferSkiaApplier.cpp:
 Added.
(WebCore::FEComponentTransferSkiaApplier::apply const):
* 
Source/WebCore/platform/graphics/filters/skia/FEComponentTransferSkiaApplier.h: 
Added.
* Source/WebCore/platform/graphics/filters/skia/FEDropShadowSkiaApplier.cpp: 
Added.
(WebCore::FEDropShadowSkiaApplier::apply const):
* Source/WebCore/platform/graphics/filters/skia/FEDropShadowSkiaApplier.h: 
Added.

Canonical link: https://commits.webkit.org/280005@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to