Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[GPU Process] (REGRESSION r285597): Set the filterRegion of the CSSFi…
…lter after it is created https://bugs.webkit.org/show_bug.cgi?id=233849 Reviewed by Cameron McCormack. Source/WebCore: In this patch: 1. sourceImageRect is no longer passed as an argument to SVGFilter. It should be passed only when SVGFilter::apply() is called. 2. CSSFilter::create() will create and build the FilterFunctions from the FilterOperations. So we have to pass the targetBoundingBox since the FilterEffects will need it when calculating the outsets. 3. The steps in RenderLayerFilters::beginFilterEffect() are: a) Recreate the CSSFilter if the targetBoundingBox changes. b) Calculate the filterRegion = targetBoundingBox + outsets c) Clamp the filterRegion if needed. This will change the filterScale. d) Set sourceImageRect = filterRegion. e) Recreate the sourceImage if needed. f) setup the context for drawing the target renderer. 4. Managing the targetBoundingBox and the filterRegion is moved from CSSFilter to RenderLayerFilters. * css/CSSFilterImageValue.cpp: (WebCore::CSSFilterImageValue::image): * platform/graphics/filters/Filter.cpp: (WebCore::Filter::Filter): * platform/graphics/filters/Filter.h: (WebCore::Filter::Filter): * rendering/CSSFilter.cpp: (WebCore::CSSFilter::create): (WebCore::CSSFilter::CSSFilter): (WebCore::createSVGFilter): (WebCore::CSSFilter::buildFilterFunctions): (WebCore::CSSFilter::apply): (WebCore::CSSFilter::setFilterRegion): (WebCore::m_hasFilterThatShouldBeRestrictedBySecurityOrigin): Deleted. (WebCore::CSSFilter::updateBackingStoreRect): Deleted. (WebCore::CSSFilter::computeSourceImageRectForDirtyRect): Deleted. (WebCore::CSSFilter::setSourceImageRect): Deleted. * rendering/CSSFilter.h: * rendering/RenderLayerFilters.cpp: (WebCore::RenderLayerFilters::buildFilter): (WebCore::RenderLayerFilters::allocateBackingStoreIfNeeded): (WebCore::RenderLayerFilters::beginFilterEffect): (WebCore::RenderLayerFilters::applyFilterEffect): (WebCore::RenderLayerFilters::allocateBackingStore): Deleted. * rendering/RenderLayerFilters.h: * rendering/svg/RenderSVGResourceFilter.cpp: (WebCore::RenderSVGResourceFilter::applyResource): * rendering/svg/SVGRenderTreeAsText.cpp: (WebCore::writeSVGResourceContainer): * svg/graphics/filters/SVGFilter.cpp: (WebCore::SVGFilter::create): (WebCore::SVGFilter::SVGFilter): * svg/graphics/filters/SVGFilter.h: LayoutTests: Unskip layout tests which were skipped in r285597. * TestExpectations: Canonical link: https://commits.webkit.org/244878@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@286546 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
14 changed files
with
162 additions
and
118 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.