[webkit-changes] [WebKit/WebKit] 51b16e: [MSE][GStreamer] Fix non-seeking flushes
Xabier Rodríguez
noreply at github.com
Wed Nov 15 03:47:46 PST 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 51b16e1c0134194e7d37dffdfac022f531b5b677
https://github.com/WebKit/WebKit/commit/51b16e1c0134194e7d37dffdfac022f531b5b677
Author: Xabier Rodriguez-Calvar <calvaris at igalia.com>
Date: 2023-11-15 (Wed, 15 Nov 2023)
Changed paths:
A LayoutTests/media/media-source/media-source-audio-switch-expected.txt
A LayoutTests/media/media-source/media-source-audio-switch.html
M Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp
M Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h
M Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp
M Source/WebCore/platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.cpp
M Source/WebCore/platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.h
Log Message:
-----------
[MSE][GStreamer] Fix non-seeking flushes
https://bugs.webkit.org/show_bug.cgi?id=262693
Reviewed by Philippe Normand.
This reverts https://commits.webkit.org/269358@main . Problem is that you can screw quality changes as they require a
non seeking flush with an updated segment.
We still need to change the segment to use the proper playback position and we can do it by using the player's position.
Besides, as a fly-by-fix, we are solving the problem of position going back to 0 when the sinks can't provide a proper
position while it is prerolling. For that, we use the cached position of the player even if it was supposed to be
invalidated already as a best effort.
* LayoutTests/media/media-source/media-source-audio-switch-expected.txt: Added.
* LayoutTests/media/media-source/media-source-audio-switch.html: Added.
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::playbackPosition const):
(WebCore::MediaPlayerPrivateGStreamer::didEnd):
(WebCore::MediaPlayerPrivateGStreamer::setCachedPosition const):
(WebCore::MediaPlayerPrivateGStreamer::invalidateCachedPosition const):
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
* Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
(WebCore::MediaPlayerPrivateGStreamerMSE::sourceSetup):
* Source/WebCore/platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.cpp:
(webKitMediaSrcPlayer):
(webKitMediaSrcSetPlayer):
(webKitMediaSrcStreamFlush):
* Source/WebCore/platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.h:
Canonical link: https://commits.webkit.org/270764@main
More information about the webkit-changes
mailing list