Title: [257932] trunk
- Revision
- 257932
- Author
- commit-qu...@webkit.org
- Date
- 2020-03-05 11:02:53 -0800 (Thu, 05 Mar 2020)
Log Message
REGRESSION: [ Mac ] fast/canvas/webgl/texImage2D-video-flipY-false.html is Timing out
https://bugs.webkit.org/show_bug.cgi?id=205734
Source/WebCore:
Fix two bugs in MediaPlayerPrivateAVFoundationObjC causing the
preferred AVPlayerItemVideoOutput code path to not be taken, in
the situation where GPU-to-GPU copies are not possible because the
video's format doesn't allow them.
Implement currentTime, fixing longstanding bug in the
AVAssetImageGenerator fallback where only the first frame of the
video would be displayed.
Covered by existing layout test.
Patch by Kenneth Russell <k...@chromium.org> on 2020-03-05
Reviewed by Dean Jackson.
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::currentTime const):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintCurrentFrameInContext):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):
LayoutTests:
Reenable layout test on macOS.
Patch by Kenneth Russell <k...@chromium.org> on 2020-03-05
Reviewed by Dean Jackson.
* platform/mac/TestExpectations:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (257931 => 257932)
--- trunk/LayoutTests/ChangeLog 2020-03-05 18:55:52 UTC (rev 257931)
+++ trunk/LayoutTests/ChangeLog 2020-03-05 19:02:53 UTC (rev 257932)
@@ -1,3 +1,14 @@
+2020-03-05 Kenneth Russell <k...@chromium.org>
+
+ REGRESSION: [ Mac ] fast/canvas/webgl/texImage2D-video-flipY-false.html is Timing out
+ https://bugs.webkit.org/show_bug.cgi?id=205734
+
+ Reenable layout test on macOS.
+
+ Reviewed by Dean Jackson.
+
+ * platform/mac/TestExpectations:
+
2020-03-05 Jacob Uphoff <jacob_uph...@apple.com>
[ macOS iOS ] storage/indexeddb/modern/transactions-stop-on-navigation.html is flaky failing
Modified: trunk/LayoutTests/platform/mac/TestExpectations (257931 => 257932)
--- trunk/LayoutTests/platform/mac/TestExpectations 2020-03-05 18:55:52 UTC (rev 257931)
+++ trunk/LayoutTests/platform/mac/TestExpectations 2020-03-05 19:02:53 UTC (rev 257932)
@@ -2029,7 +2029,6 @@
webkit.org/b/207858 fast/canvas/webgl/draw-elements-out-of-bounds-uint-index.html [ Failure ]
webkit.org/b/207858 fast/canvas/webgl/simulated-vertexAttrib0-invalid-indicies.html [ Failure ]
webkit.org/b/207858 fast/canvas/webgl/webgl2-texture-upload-enums.html [ Failure ]
-webkit.org/b/207858 fast/canvas/webgl/texImage2D-video-flipY-false.html [ Skip ]
webkit.org/b/207858 webgl/1.0.3/conformance/programs/program-test.html [ Failure ]
webkit.org/b/207971 css3/selectors3/xml/css3-modsel-d1.xml [ Pass Failure ]
@@ -2057,4 +2056,4 @@
webkit.org/b/208519 [ Catalina ] webanimations/accelerated-animation-slot-invalidation.html [ Pass ImageOnlyFailure ]
-webkit.org/b/208574 mathml/scripts-removeChild.html [ Pass ImageOnlyFailure ]
\ No newline at end of file
+webkit.org/b/208574 mathml/scripts-removeChild.html [ Pass ImageOnlyFailure ]
Modified: trunk/Source/WebCore/ChangeLog (257931 => 257932)
--- trunk/Source/WebCore/ChangeLog 2020-03-05 18:55:52 UTC (rev 257931)
+++ trunk/Source/WebCore/ChangeLog 2020-03-05 19:02:53 UTC (rev 257932)
@@ -1,3 +1,27 @@
+2020-03-05 Kenneth Russell <k...@chromium.org>
+
+ REGRESSION: [ Mac ] fast/canvas/webgl/texImage2D-video-flipY-false.html is Timing out
+ https://bugs.webkit.org/show_bug.cgi?id=205734
+
+ Fix two bugs in MediaPlayerPrivateAVFoundationObjC causing the
+ preferred AVPlayerItemVideoOutput code path to not be taken, in
+ the situation where GPU-to-GPU copies are not possible because the
+ video's format doesn't allow them.
+
+ Implement currentTime, fixing longstanding bug in the
+ AVAssetImageGenerator fallback where only the first frame of the
+ video would be displayed.
+
+ Covered by existing layout test.
+
+ Reviewed by Dean Jackson.
+
+ * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
+ * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
+ (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTime const):
+ (WebCore::MediaPlayerPrivateAVFoundationObjC::paintCurrentFrameInContext):
+ (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):
+
2020-03-05 youenn fablet <you...@apple.com>
In case an activating service worker is terminated, it should go to activated state
Modified: trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h (257931 => 257932)
--- trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h 2020-03-05 18:55:52 UTC (rev 257931)
+++ trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h 2020-03-05 19:02:53 UTC (rev 257932)
@@ -153,6 +153,7 @@
bool waitingForKey() const final { return m_waitingForKey; }
#endif
+ float currentTime() const override;
MediaTime currentMediaTime() const override;
private:
Modified: trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm (257931 => 257932)
--- trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm 2020-03-05 18:55:52 UTC (rev 257931)
+++ trunk/Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm 2020-03-05 19:02:53 UTC (rev 257932)
@@ -1222,6 +1222,11 @@
return MediaTime::invalidTime();
}
+float MediaPlayerPrivateAVFoundationObjC::currentTime() const
+{
+ return currentMediaTime().toFloat();
+}
+
MediaTime MediaPlayerPrivateAVFoundationObjC::currentMediaTime() const
{
if (!metaDataAvailable() || !m_avPlayerItem)
@@ -1498,7 +1503,16 @@
setDelayCallbacks(true);
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- if (videoOutputHasAvailableFrame())
+ // Callers of this will often call copyVideoTextureToPlatformTexture first,
+ // which calls updateLastPixelBuffer, which clears m_lastImage whenever the
+ // video delivers a new frame. This breaks videoOutputHasAvailableFrame's
+ // short-circuiting when m_lastImage is non-null, but the video often
+ // doesn't have a new frame to deliver since the last time
+ // hasNewPixelBufferForItemTime was called against m_videoOutput. To avoid
+ // changing the semantics of videoOutputHasAvailableFrame in ways that might
+ // break other callers, look for production of a recent pixel buffer from
+ // the video output, too.
+ if (videoOutputHasAvailableFrame() || (m_videoOutput && m_lastPixelBuffer))
paintWithVideoOutput(context, rect);
else
paintWithImageGenerator(context, rect);
@@ -2220,7 +2234,11 @@
void MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput(GraphicsContext& context, const FloatRect& outputRect)
{
- updateLastImage(UpdateType::UpdateSynchronously);
+ // It's crucial to not wait synchronously for the next image. Videos that
+ // come down this path are performing slow-case software uploads, and such
+ // videos may not return metadata in a timely fashion. Use the most recently
+ // available pixel buffer, if any.
+ updateLastImage();
if (!m_lastImage)
return;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes