Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: f2797a15c336841f348b94902c3dd556a0cd5540
https://github.com/WebKit/WebKit/commit/f2797a15c336841f348b94902c3dd556a0cd5540
Author: Philippe Normand <[email protected]>
Date: 2026-07-23 (Thu, 23 Jul 2026)
Changed paths:
M Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp
M Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h
M
Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h
Log Message:
-----------
[GStreamer] Teardown media players corresponding to media elements moving
outside of viewport
https://bugs.webkit.org/show_bug.cgi?id=319380
Reviewed by Xabier Rodriguez-Calvar.
Setting the pipeline state of non-MSE players to NULL when its corresponding
media element has moved
out of the viewport helps keeping the amount of alive video decoders at bay.
This is specially
useful when browsing some Reddit, Snapchat and similar pages containing lots of
auto-playing muted
videos.
Using this approach for MSE players could be useful as well but would likely be
more complex to
implement due to implications at the SourceBuffer level.
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::updateStates):
(WebCore::MediaPlayerPrivateGStreamer::managePlayerSuspend):
(WebCore::MediaPlayerPrivateGStreamer::suspendTargetState):
* Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
Canonical link: https://commits.webkit.org/317766@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications