This website requires JavaScript.
Explore
Help
Sign In
nephele
/
haikuwebkit
Watch
1
Star
0
Fork
You've already forked haikuwebkit
0
Code
Issues
Releases
Activity
haiku
haikuwebkit
/
LayoutTests
/
animations
/
steps-transform-rendering-u...
7 lines
87 B
Plaintext
Raw
Permalink
Normal View
History
Unescape
Escape
steps() timing function on a transform animation triggers a render every frame https://bugs.webkit.org/show_bug.cgi?id=214712 <rdar://problem/62737868> Reviewed by Tim Horton. Source/WebCore: An animation of transform, with a steps() timing function, would schedule a rendering update on every frame. This happened because KeyframeEffect::updateAcceleratedActions() would keep trying, and failing to start the accelerated animation every frame, since GraphicsLayerCA refuses to run accelerated animations with steps timing functions. Fix by making m_isRunningAccelerated an Optional<>, which gets a value once we've tried to run the animation the first time. Also ensure that we re-try if the timing function changes, via animationDidChangeTimingProperties(). Test: animations/steps-transform-rendering-updates.html * animation/KeyframeEffect.cpp: (WebCore::KeyframeEffect::isRunningAcceleratedAnimationForProperty const): (WebCore::KeyframeEffect::updateAcceleratedActions): (WebCore::KeyframeEffect::animationDidChangeTimingProperties): (WebCore::KeyframeEffect::animationWasCanceled): (WebCore::KeyframeEffect::willChangeRenderer): (WebCore::KeyframeEffect::animationSuspensionStateDidChange): (WebCore::KeyframeEffect::applyPendingAcceleratedActions): * animation/KeyframeEffect.h: (WebCore::KeyframeEffect::isRunningAccelerated const): * page/Page.cpp: (WebCore::Page::startTrackingRenderingUpdates): (WebCore::Page::renderingUpdateCount const): (WebCore::Page::updateRendering): * page/Page.h: * testing/Internals.cpp: (WebCore::Internals::startTrackingRenderingUpdates): (WebCore::Internals::renderingUpdateCount): * testing/Internals.h: * testing/Internals.idl: LayoutTests: * animations/steps-transform-rendering-updates-expected.txt: Added. * animations/steps-transform-rendering-updates.html: Added. Canonical link: https://commits.webkit.org/227580@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@264856 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2020-07-24 21:03:23 +00:00
PASS count is 0
Step animations invalidate style on every rendering update whether or not they need to https://bugs.webkit.org/show_bug.cgi?id=215229 <rdar://problem/66636153> Reviewed by Antoine Quint. Source/WebCore: Step timing functions with transforms try and fail to start accelerated which causes them to repeatedly schedule unnecessary rendering updates. * animation/KeyframeEffect.cpp: (WebCore::KeyframeEffect::updateAcceleratedActions): Step timing functions are never accelerated so don't bother trying to start them in accelerated state. This is similar to treatmeant of unaccelerated properties. LayoutTests: * animations/steps-transform-rendering-updates-expected.txt: Canonical link: https://commits.webkit.org/228686@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266232 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2020-08-27 15:42:07 +00:00
PASS count < 6 is true
steps() timing function on a transform animation triggers a render every frame https://bugs.webkit.org/show_bug.cgi?id=214712 <rdar://problem/62737868> Reviewed by Tim Horton. Source/WebCore: An animation of transform, with a steps() timing function, would schedule a rendering update on every frame. This happened because KeyframeEffect::updateAcceleratedActions() would keep trying, and failing to start the accelerated animation every frame, since GraphicsLayerCA refuses to run accelerated animations with steps timing functions. Fix by making m_isRunningAccelerated an Optional<>, which gets a value once we've tried to run the animation the first time. Also ensure that we re-try if the timing function changes, via animationDidChangeTimingProperties(). Test: animations/steps-transform-rendering-updates.html * animation/KeyframeEffect.cpp: (WebCore::KeyframeEffect::isRunningAcceleratedAnimationForProperty const): (WebCore::KeyframeEffect::updateAcceleratedActions): (WebCore::KeyframeEffect::animationDidChangeTimingProperties): (WebCore::KeyframeEffect::animationWasCanceled): (WebCore::KeyframeEffect::willChangeRenderer): (WebCore::KeyframeEffect::animationSuspensionStateDidChange): (WebCore::KeyframeEffect::applyPendingAcceleratedActions): * animation/KeyframeEffect.h: (WebCore::KeyframeEffect::isRunningAccelerated const): * page/Page.cpp: (WebCore::Page::startTrackingRenderingUpdates): (WebCore::Page::renderingUpdateCount const): (WebCore::Page::updateRendering): * page/Page.h: * testing/Internals.cpp: (WebCore::Internals::startTrackingRenderingUpdates): (WebCore::Internals::renderingUpdateCount): * testing/Internals.h: * testing/Internals.idl: LayoutTests: * animations/steps-transform-rendering-updates-expected.txt: Added. * animations/steps-transform-rendering-updates.html: Added. Canonical link: https://commits.webkit.org/227580@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@264856 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2020-07-24 21:03:23 +00:00
PASS successfullyParsed is true
TEST COMPLETE