Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: de98f6bb5014db381fd8fe98ecf8a5977d6c3521
https://github.com/WebKit/WebKit/commit/de98f6bb5014db381fd8fe98ecf8a5977d6c3521
Author: Enrique Ocaña González <[email protected]>
Date: 2026-03-03 (Tue, 03 Mar 2026)
Changed paths:
M Source/WebCore/platform/graphics/gstreamer/GStreamerRegistryScanner.cpp
Log Message:
-----------
[GStreamer] Expose VIDEO_DECODING_LIMIT through an environment variable
https://bugs.webkit.org/show_bug.cgi?id=308969
Reviewed by Alicia Boya Garcia and Xabier Rodriguez-Calvar.
The RDK-E downstream platform would like to have a single unified build
for many kind of devices. For that reason, the platform compile-time
VIDEO_DECODING_LIMIT restriction aren't appropriate anymore, since the
same build can be used for devices with different runtime limits. A way
to specify the decoding limit ar runtime would be desirable.
An environment variable looks like a better way to do it than a runtime
setting, since the limit is unlikely to change at runtime and likely to
change per device (with a value consistent on every execution).
Moreover, having a setting would mean extra changes in the dependent
packages that embed WebKit, while having en environmente variable would
be less intrusive and would only mean a change in the (easier to
maintain) startup scripts.
This change adds WEBKIT_GST_VIDEO_DECODING_LIMIT env on top of
VIDEO_DECODING_LIMIT compile time option to limit video decoding
capabilities. WEBKIT_GST_VIDEO_DECODING_LIMIT can now be set in runtime
and it takes precedence over compile time definition
VIDEO_DECODING_LIMIT.
See: https://github.com/WebPlatformForEmbedded/WPEWebKit/pull/1625
https://github.com/WebPlatformForEmbedded/WPEWebKit/pull/1626
Original author: Andrzej Surdej <[email protected]>
* Source/WebCore/platform/graphics/gstreamer/GStreamerRegistryScanner.cpp:
(videoDecoderLimitsDefaults): Deleted.
* Source/WebCore/platform/graphics/gstreamer/GStreamerRegistryScanner.cpp:
(WebCore::parseVideoDecodingLimit): Use a StringView to prevent extra copies.
(WebCore::resolveVideoDecodingLimits): Decide the right decoding limits
considering the build time option and the environment variable value.
(WebCore::GStreamerRegistryScanner::isContentTypeSupported const): Parse env
var and only require the build ifdefs when strictly needed.
(videoDecoderLimitsDefaults): Deleted.
Canonical link: https://commits.webkit.org/308552@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications