[webkit-changes] [WebKit/WebKit] bc8bd3: [GStreamer] Looped video is not seamless (flicker ...
Philippe Normand
noreply at github.com
Tue May 9 04:25:12 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: bc8bd3bac663f00e61c47c23bded08056ca348b0
https://github.com/WebKit/WebKit/commit/bc8bd3bac663f00e61c47c23bded08056ca348b0
Author: Philippe Normand <philn at igalia.com>
Date: 2023-05-09 (Tue, 09 May 2023)
Changed paths:
M LayoutTests/media/video-played-collapse.html
M Source/WebCore/html/HTMLMediaElement.cpp
M Source/WebCore/platform/graphics/MediaPlayer.cpp
M Source/WebCore/platform/graphics/MediaPlayer.h
M Source/WebCore/platform/graphics/MediaPlayerPrivate.h
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/MediaPlayerPrivateGStreamerMSE.h
Log Message:
-----------
[GStreamer] Looped video is not seamless (flicker inbetween loops)
https://bugs.webkit.org/show_bug.cgi?id=227687
Reviewed by Xabier Rodriguez-Calvar.
When the media element has its loop attribute set to true the player now performs SEGMENT
non-flushing seeks to seek back to the beginning of the media. This ensures a seamless behavior as
the pipeline state doesn't change and sinks don't flush. This can be done only on a playing pipeline
though, because the segment seek is non-flushing. So when a seek is requested on a paused looping
player we have to enable flush, this is a corner case issue though.
* Source/WebCore/html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):
(WebCore::HTMLMediaElement::setLoop):
* Source/WebCore/platform/graphics/MediaPlayer.cpp:
(WebCore::MediaPlayer::isLoopingChanged):
* Source/WebCore/platform/graphics/MediaPlayer.h:
* Source/WebCore/platform/graphics/MediaPlayerPrivate.h:
(WebCore::MediaPlayerPrivateInterface::isLoopingChanged):
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
(WebCore::MediaPlayerPrivateGStreamer::play):
(WebCore::MediaPlayerPrivateGStreamer::doSeek):
(WebCore::MediaPlayerPrivateGStreamer::seek):
(WebCore::MediaPlayerPrivateGStreamer::updatePlaybackRate):
(WebCore::MediaPlayerPrivateGStreamer::handleMessage):
(WebCore::MediaPlayerPrivateGStreamer::updateStates):
(WebCore::MediaPlayerPrivateGStreamer::didEnd):
(WebCore::MediaPlayerPrivateGStreamer::isLoopingChanged):
(WebCore::MediaPlayerPrivateGStreamer::ensureSeekFlags):
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
* Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
(WebCore::MediaPlayerPrivateGStreamerMSE::seek):
(WebCore::MediaPlayerPrivateGStreamerMSE::doSeek):
* Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h:
Canonical link: https://commits.webkit.org/263860@main
More information about the webkit-changes
mailing list