[webkit-changes] [WebKit/WebKit] fd6859: [web-animations] ensure accelerated effects do not...
Antoine Quint
noreply at github.com
Fri Mar 3 02:56:09 PST 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: fd6859ad60cd1cb51fabdb4169bf0e4de09f502a
https://github.com/WebKit/WebKit/commit/fd6859ad60cd1cb51fabdb4169bf0e4de09f502a
Author: Antoine Quint <graouts at webkit.org>
Date: 2023-03-03 (Fri, 03 Mar 2023)
Changed paths:
M Source/WebCore/platform/animation/AcceleratedEffect.cpp
M Source/WebCore/platform/animation/AcceleratedEffect.h
M Source/WebCore/platform/animation/AcceleratedEffectValues.cpp
M Source/WebCore/platform/animation/AcceleratedEffectValues.h
M Source/WebCore/platform/graphics/transforms/TransformOperation.h
M Source/WebCore/platform/graphics/transforms/TranslateTransformOperation.cpp
M Source/WebCore/platform/graphics/transforms/TranslateTransformOperation.h
M Source/WebCore/rendering/RenderLayerBacking.cpp
Log Message:
-----------
[web-animations] ensure accelerated effects do not contain calculated values
https://bugs.webkit.org/show_bug.cgi?id=253243
Reviewed by Dean Jackson.
Since we will lack the ability to encode calculated values when committing PlatformCALayerRemote,
we must ensure those values are pre-calculated when the accelerated effect is created.
To do this, we pass down the border box of the RenderLayerBacking's associated renderer down to
AcceleratedEffectValues to correctly resolve any Length-backed value that is calculated. In the
case of transform operations, we add a new selfOrCopyWithResolvedCalculatedValues() method that
will only create a new operation if needed.
* Source/WebCore/platform/animation/AcceleratedEffect.cpp:
(WebCore::AcceleratedEffect::create):
(WebCore::AcceleratedEffect::copyWithProperties):
(WebCore::AcceleratedEffect::AcceleratedEffect):
* Source/WebCore/platform/animation/AcceleratedEffect.h:
* Source/WebCore/platform/animation/AcceleratedEffectValues.cpp:
(WebCore::AcceleratedEffectValues::AcceleratedEffectValues):
(WebCore::nonCalculatedLengthPoint):
(WebCore::AcceleratedEffectValues::copyTransformOperations): Deleted.
* Source/WebCore/platform/animation/AcceleratedEffectValues.h:
* Source/WebCore/platform/graphics/transforms/TransformOperation.h:
(WebCore::TransformOperation::selfOrCopyWithResolvedCalculatedValues):
* Source/WebCore/platform/graphics/transforms/TranslateTransformOperation.cpp:
(WebCore::TranslateTransformOperation::selfOrCopyWithResolvedCalculatedValues):
* Source/WebCore/platform/graphics/transforms/TranslateTransformOperation.h:
* Source/WebCore/rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateAcceleratedEffectsAndBaseValues):
Canonical link: https://commits.webkit.org/261132@main
More information about the webkit-changes
mailing list