Changeset 268746 in webkit
- Timestamp:
- Oct 20, 2020, 10:34:38 AM (6 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/TestExpectations (modified) (1 diff)
-
LayoutTests/platform/mac/TestExpectations (modified) (1 diff)
-
LayoutTests/platform/win/TestExpectations (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp (modified) (4 diffs)
-
Source/WebCore/platform/graphics/ca/GraphicsLayerCA.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r268745 r268746 1 2020-10-20 Antoine Quint <graouts@webkit.org> 2 3 REGRESSION(r268615): some accelerated transform tests are failing 4 https://bugs.webkit.org/show_bug.cgi?id=217851 5 <rdar://problem/70394402> 6 7 Reviewed by Dean Jackson. 8 9 Remove flaky epectations for affected tests and skip tests on Windows where failures remain. 10 11 * TestExpectations: 12 * platform/mac/TestExpectations: 13 * platform/win/TestExpectations: 14 1 15 2020-10-20 Rob Buis <rbuis@igalia.com> 2 16 -
trunk/LayoutTests/TestExpectations
r268734 r268746 4519 4519 fast/layoutformattingcontext/ [ ImageOnlyFailure ] 4520 4520 webkit.org/b/217054 fast/layoutformattingcontext/horizontal-sizing-with-trailing-letter-spacing.html [ Skip ] 4521 4522 webkit.org/b/217851 transitions/interrupted-transition-hardware.html [ Pass Failure ]4523 webkit.org/b/217851 webanimations/accelerated-transform-related-animation-property-order.html [ Pass Failure ]4524 webkit.org/b/217851 webanimations/accelerated-translate-animation-additional-animation-added-in-flight.html [ Pass Failure ]4525 webkit.org/b/217851 webanimations/accelerated-translate-animation-underlying-transform-changed-in-flight.html [ Pass Failure ]4526 webkit.org/b/217851 webanimations/accelerated-translate-animation-with-transform.html [ Pass Failure ]4527 webkit.org/b/217851 webanimations/accelerated-translate-animation.html [ Pass Failure ] -
trunk/LayoutTests/platform/mac/TestExpectations
r268713 r268746 2247 2247 webkit.org/b/217620 inspector/audit/basic-async.htm [ Pass Timeout ] 2248 2248 2249 # These are failing on Mojave due to an error in the way CA animations are applied.2250 # https://bugs.webkit.org/show_bug.cgi?id=2178422251 [ Mojave ] transitions/interrupted-transition-hardware.html [ Pass Failure ]2252 [ Mojave ] webanimations/accelerated-transform-related-animation-property-order.html [ Pass Failure ]2253 [ Mojave ] webanimations/accelerated-translate-animation-additional-animation-added-in-flight.html [ Pass Failure ]2254 [ Mojave ] webanimations/accelerated-translate-animation-underlying-transform-changed-in-flight.html [ Pass Failure ]2255 [ Mojave ] webanimations/accelerated-translate-animation-with-transform.html [ Pass Failure ]2256 [ Mojave ] webanimations/accelerated-translate-animation.html [ Pass Failure ]2257 2258 2249 webkit.org/b/217931 imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/moving-between-documents/before-prepare-createHTMLDocument-success-empty-src-module.html [ Pass Failure ] 2259 2250 -
trunk/LayoutTests/platform/win/TestExpectations
r268692 r268746 4587 4587 webkit.org/b/217812 transforms/2d/translate-change-composited.html [ Skip ] 4588 4588 webkit.org/b/217812 transforms/2d/rotate-composited.html [ Skip ] 4589 webkit.org/b/217812 webanimations/accelerated-transform-related-animation-property-order.html [ Skip ] 4590 webkit.org/b/217812 webanimations/accelerated-translate-animation-additional-animation-added-in-flight.html [ Skip ] 4591 webkit.org/b/217812 webanimations/accelerated-translate-animation-underlying-transform-changed-in-flight.html [ Skip ] 4592 webkit.org/b/217812 webanimations/accelerated-translate-animation-with-transform.html [ Skip ] 4593 webkit.org/b/217812 webanimations/accelerated-translate-animation.html [ Skip ] 4589 4594 4590 4595 webkit.org/b/217922 [ Release ] animations/additive-transform-animations.html [ ImageOnlyFailure ] 4591 4596 webkit.org/b/217922 animations/needs-layout.html [ ImageOnlyFailure ] 4592 4597 webkit.org/b/217922 fast/animation/animation-mixed-transform-crash.html [ ImageOnlyFailure ] 4593 -
trunk/Source/WebCore/ChangeLog
r268745 r268746 1 2020-10-20 Antoine Quint <graouts@webkit.org> 2 3 REGRESSION(r268615): some accelerated transform tests are failing 4 https://bugs.webkit.org/show_bug.cgi?id=217851 5 <rdar://problem/70394402> 6 7 Reviewed by Dean Jackson. 8 9 When we added support for accelerated individual transform properties animations, we added 10 the notion of base transform animations which are used to set the base value of any 11 transform-related property that is not animated. 12 13 Those animations were defined to start as early as possible, assuming that a very small value 14 after 0s was as early as possible. However, it's possible that other animations start with a 15 negative time if they have a delay or are seeked, if the value returned by CACurrentMediaTime() 16 is smaller than that delay. This means that if the machine had been booted for less time than 17 an accelerated animation's delay, the base transform animation wouldn't overlap. 18 19 We now ensure that those base transform animations start as early as the earliest animation 20 that is being committed in a call to GraphicsLayerCA::updateAnimations(). 21 22 * platform/graphics/ca/GraphicsLayerCA.cpp: 23 (WebCore::GraphicsLayerCA::updateAnimations): 24 (WebCore::GraphicsLayerCA::setAnimationOnLayer): 25 * platform/graphics/ca/GraphicsLayerCA.h: 26 (WebCore::GraphicsLayerCA::LayerPropertyAnimation::computedBeginTime const): 27 1 28 2020-10-20 Rob Buis <rbuis@igalia.com> 2 29 -
trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp
r268714 r268746 2862 2862 void GraphicsLayerCA::updateAnimations() 2863 2863 { 2864 auto baseTransformAnimationBeginTime = 1_s; 2865 auto currentTime = Seconds(CACurrentMediaTime()); 2866 auto updateBeginTimes = [&](LayerPropertyAnimation& animation) 2867 { 2868 if (animation.m_pendingRemoval) 2869 return; 2870 2871 // In case we have an offset, and we haven't set an explicit begin time previously, 2872 // we need to record the beginTime now. 2873 if (animation.m_timeOffset && !animation.m_beginTime) 2874 animation.m_beginTime = currentTime; 2875 2876 // Now check if we have a resolved begin time and ensure the begin time we'll use for 2877 // base transform animations matches the smallest known begin time to guarantee that 2878 // such animations can combine with other explicit transform animations correctly. 2879 if (auto computedBeginTime = animation.computedBeginTime()) 2880 baseTransformAnimationBeginTime = std::min(baseTransformAnimationBeginTime, *computedBeginTime); 2881 }; 2882 2864 2883 enum class Additive { Yes, No }; 2865 2884 auto addAnimation = [&](LayerPropertyAnimation& animation, Additive additive = Additive::Yes) { … … 2891 2910 // To ensure the base value transform is applied along with all the interpolating animations, we set it to have started 2892 2911 // as early as possible, which combined with the infinite duration ensures it's current for any given CA media time. 2893 animation.m_beginTime = Seconds::fromNanoseconds(1);2912 animation.m_beginTime = baseTransformAnimationBeginTime; 2894 2913 2895 2914 // Additivity will depend on the source of the matrix, if it was explicitly provided as an identity matrix, it … … 2901 2920 }; 2902 2921 2903 // Remove all running CA animations. 2922 // Iterate through all animations to update each animation's begin time, if necessary, 2923 // compute the base transform animation begin times and remove all running CA animations. 2904 2924 for (auto& animation : m_animations) { 2925 updateBeginTimes(animation); 2905 2926 if (animation.m_playState == PlayState::Playing || animation.m_playState == PlayState::Paused) 2906 2927 removeCAAnimationFromLayer(animation); … … 3022 3043 auto& caAnim = *animation.m_animation; 3023 3044 3024 if (animation.m_timeOffset) { 3025 // In case we have an offset, we need to record the beginTime now since we have to pass in an explicit 3026 // value in the first place. 3027 if (!animation.m_beginTime) 3028 animation.m_beginTime = Seconds(CACurrentMediaTime()); 3029 caAnim.setBeginTime((animation.m_beginTime - animation.m_timeOffset).seconds()); 3030 } else if (animation.m_beginTime) { 3031 // If we already have a begin time, then we already started in the past and must ensure we use that same 3032 // begin time. Any other case will get use the CA transaction's time as its begin time and will be recorded 3033 // in platformCALayerAnimationStarted(). 3034 caAnim.setBeginTime(animation.m_beginTime.seconds()); 3035 } 3045 if (auto beginTime = animation.computedBeginTime()) 3046 caAnim.setBeginTime(beginTime->seconds()); 3036 3047 3037 3048 String animationID = animation.animationIdentifier(); -
trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.h
r268615 r268746 31 31 #include "PlatformCALayerClient.h" 32 32 #include <wtf/HashMap.h> 33 #include <wtf/Optional.h> 33 34 #include <wtf/RetainPtr.h> 34 35 #include <wtf/text/StringHash.h> … … 463 464 464 465 String animationIdentifier() const { return makeString(m_name, '_', static_cast<unsigned>(m_property), '_', m_index, '_', m_subIndex); } 466 Optional<Seconds> computedBeginTime() const 467 { 468 if (m_beginTime) 469 return m_beginTime - m_timeOffset; 470 return WTF::nullopt; 471 } 465 472 466 473 RefPtr<PlatformCAAnimation> m_animation;
Note:
See TracChangeset
for help on using the changeset viewer.