122918 Commits

Author SHA1 Message Date
Julian Bouzas
30aa1e84e4 lcevcdec: Handle pixel aspect ratio and crop size correctly
LCEVCdec supports different pixel aspect ratios other than 1/1. This change
forwards the pixel aspect ratio of the base picture to the LCEVC decoder,
and also updates the output pixel aspect ratio caps base on the one from the
enhanced frame.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9463>
2025-08-21 14:00:55 +00:00
Julian Bouzas
d66213bfa3 lcevcdec: Peek the decoder for output resolution
The output resolution is not always twice as big as the input resultion divided
by the pixel aspect ratio. This is the case for LCEVC '0D' mode, where the
output resolution is the same as the input resolution, and the only enhancement
is the picture being clearer.

This patch uses LCEVC_PeekDecoder() after sending the LCEVC enhancement data to
know what the output resolution will be before allocating the output picture.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9463>
2025-08-21 14:00:54 +00:00
Julian Bouzas
3208d6c62a lcevcdec: Fix LCEVC picture access flags
Even though the LCEVC decoder works fine without this, it is recommended to
set read access to base pictures that are sent to the decoder, and write access
to enhanced pictures that are received from the decoder.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9463>
2025-08-21 14:00:54 +00:00
Julian Bouzas
265b69520a lcevcdec: Fix width type typo
This was always meant to be gint instead of gint32.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9463>
2025-08-21 14:00:53 +00:00
Vivienne Watermeier
54d28569b2 baseparse: don't clear most sticky events after a FLUSH_STOP event
Clearing sticky events - besides EOS, STREAM_GROUP_DONE, and SEGMENT -
risks losing them if a flush occurs before we get another buffer.

Also adds a unit test: parser_sticky_events_after_flush

Fixes #4193

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9506>
2025-08-21 11:00:36 +00:00
Víctor Manuel Jáquez Leal
fc647552fa vulkan: enable video maintenance2 for inline session parameters
.. in decoders.

Inline session parameters allows to not create session parameters handlers for
every new stream parameters (such as SPS and PPS for H.264, for example), but
instead to pass them as a chained structure in the decoding main structure. This
is completely align with GStreamer decoder base classes.

Even that the previous approach is kept, if the devices doesn't support video
maintenance2, it shows a lot of validation errors.

Also it was required to add another parameter when enabling extension to verify
if the extension is linked with a device feature and if it is enabled.

Bump Vulkan API (and driver version for both decoders and encoders) to 1.4.306

Also bumped the ABI_CHECK_TAG because the CI finally catches up with the vulkan
video symbols that are not exposed by a public header (tough they are binary
public).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9585>
2025-08-21 05:22:19 +00:00
Víctor Manuel Jáquez Leal
8ce2ed05ac vkvideo-private: remove unused guards
Since this file is compiled only if vulkan video support is enabled with the
proper vulkan headers version.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9585>
2025-08-21 05:22:19 +00:00
Víctor Manuel Jáquez Leal
1d60643a1a vkdevice: check for features when enabling extensions
Some extensions need to have enabled certain feature in the device. This patch
does that check by adding a new field in the extension list which is a function
that can be mapped to gst_vulkan_physical_device_has_feature_*() functions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9585>
2025-08-21 05:22:18 +00:00
Víctor Manuel Jáquez Leal
caae3b07e1 vkimagesbufferpool: another usage for non-independent profile flag
Fix validation issue VUID-VkImageCreateInfo-flags-08329 on old RADV hardwware.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9591>
2025-08-20 20:11:24 +02:00
Víctor Manuel Jáquez Leal
48dd6aee51 vulkanh265dec: fix validation layer complain
Silence the validation VUID-VkImageMemoryBarrier2-srcAccessMask-03915

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9591>
2025-08-20 20:11:18 +02:00
Ian Napier
aee742223c decklinkvideosrc: fix decklinkvideosrc becomes unrecoverable if it fails to start streaming
See #2611

When transitioning to PLAYING we call IDeckLinkInput::StartStreams() (via GstDecklinkInput::start_streams). This can
fail for various reasons, including if the hardware device is already in use.

Previously, we logged StartStreams() failure as an element error but otherwise continued to successfully transition to
PLAYING. Now, if StartStreams() returns an error we fail the state change.

If StartStreams() fails then a subsequent call to StopStreams(), when transitioning PAUSED to READY, will also fail.

Previously, if StopStreams() failed then the state change also failed. Unfortunately this prevented the element from
later being disposed, which in turn meant the associated hardware resources was never freed. Consequently, if a
decklinkvideosrc failed to transition PAUSED to READY, then the associated hardware device could not subsequently be
used by any other decklinkvideosrc.

Now, we log an element error if StopStreams() fails but otherwise consider the state change to have succeeded. This
means that the element can be disposed and the associated hardware resource released.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9578>
2025-08-20 11:38:03 +00:00
Víctor Manuel Jáquez Leal
6d53576194 vkimagebufferpool: don't use independent profile flag for some usage
VK_IMAGE_USAGE_VIDEO_ENCODE_DPB_BIT_KHR, among others, needs the video profile
to use.

The patch clears the validation issue  VUID-VkImageCreateInfo-flags-08331

This is a continuation of !9550

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9570>
2025-08-20 06:37:03 +00:00
L. E. Segovia
2dd28e36e6 glib: update to 2.82.5 and backport shebangs patch
Fixes Meson 1.8 and higher's detection of the shebang for glib-mkenums
and glib-genmarshal.

See https://github.com/mesonbuild/meson/issues/14896

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9561>
2025-08-19 22:21:15 +00:00
Thibault Saunier
c8db458ce9 ges: Set framerate caps filter on the last time effect
The responsibility to change the framerate to the one
requested on the VideoTrack should always be the last time effect in it.

This introduces a new `capsfilter` at the end of video effect that
will be in passthrough most of the time.
t show

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
fac2d62054 validate: videorate: Update tests to use fakevideodec and fix race condition
There was a case where we could end up having more buffers on the sinkpads
than what was expected, depending on timings. This ensure that we have a fixed
number of buffers produced by the testsrc, and we play until EOS.

Replace theora encoder/decoder chain with fakevideodec for testing
QoS handling in videorate rate property tests. This simplifies the
test pipeline and removes dependency on theora codecs.

Also adjust test expectations to match RGBA format output from
fakevideodec instead of I420 from theoradec, and limit buffer
counts to make tests more deterministic.

This also fixes the rate we set for 2.0 test as we were actually testing
0.5 there.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
efdc9b1aea validate: scenario: Clear wait_message_action on stop
When executing a stop action, ensure that any pending wait_message_action
is cleared and unreffed to prevent it from being executed after the
scenario has been stopped. This prevents potential crashes or unexpected
behavior when stopping a scenario that has a pending wait action.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
fe6ad6f370 validate: scenario: Fix NULL context usage in action done callback
Use the local context variable that was retrieved earlier instead of
action->priv->context which is always NULL at this point since we
reset it right before. This ensures we invoke the callback on the
correct context.

And make sure that the wait message still has a reference when setting done
otherwise it is unref before calling the context invoke function

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
f99bf2abee validate: Add support for overrides field in meta structure
Add support for an 'overrides' field in validatetest meta structures that
allows changing issue severity levels during test execution. This enables
tests to pass when encountering known issues by downgrading their severity.

The overrides field accepts an array of change-severity structures with:
- issue-id: The issue ID to override
- new-severity: New severity level (critical, warning, issue, ignore)

Currently only change-severity overrides are supported. The feature follows
the same pattern as expected-issues and is only available in .validatetest
files, not .scenario files.

Includes comprehensive documentation and a test case demonstrating the
functionality.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:50 +00:00
Thibault Saunier
0b745f67db videorate: Convert input ts to output scale to close segment
Otherwise we compare values that are in two different time scales.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:50 +00:00
Thibault Saunier
e697fe98eb videorate: Bring all timestamp in the runtime scale when applying rate to QoS
Otherwise the timescale won't match and we might end up with totally broken
QoS events.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:50 +00:00
Thibault Saunier
51d43529c3 videorate: Refactor so upstream/downstream time domains are properly decoupled
Refactor the videorate element to properly separate upstream and downstream
time domains when the `rate` property is set.

The previous implementation had issues with time domain conversions when
changing rates, especially during seeks after which we were basically confusing
input and output timestamps.

This also fixes rate changes as we are now tracking the wanted input timestamps
and not confusing them with the output, so this way we do not drop buffers when
the rate is changed while playing, meaning that the related tests have been
fixed

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:49 +00:00
Thibault Saunier
242b4fa931 videorate: Handle the case where the base_ts is > qo.timestamp
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:49 +00:00
Thibault Saunier
d21c1f13d1 videorate: Do not fail setting caps on flushing pad
Avoiding to error out when flushing "at the wrong time" for example.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:49 +00:00
Thibault Saunier
3715b0b7b8 debugutils: Use SHOW_FULL_PARAMS when GstDotsTracer is active
When the dots tracer is detected among active tracers, switch from
SHOW_ALL to SHOW_FULL_PARAMS to prevent parameter ellipsization.
The dots tracer is designed to work with gst-dots-viewer which can
handle long parameter values, so we preserve the full text in dot files.

This improves the viewing experience when using the dots tracer with
the gst-dots-viewer tool.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:45 +00:00
Thibault Saunier
e87b3b0359 tracerutils: keep tracers that do not register to any hook alive as others
This checks if a tracer has registered to any hook after
initialization and automatically registers it to the "none" hook if not
so the lifetime of those tracer is the same as tracer who registers to hooks.

For example the `dots` tracer was being freed right after initialization
which was unexpected.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:45 +00:00
Thibault Saunier
775187188d dots-viewer: Reindent and remove unused code in jquery.graphviz.svg.js
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
d3ad6136ef dots-viewer: Refactor JavaScript into modular architecture
Split monolithic embedded JavaScript in overlay.html into dedicated modules:
- tooltip.js: Custom tooltip functionality with interactive copy/paste mode
- pipeline-navigation.js: Clickable pipeline-dot references for navigation
- text-ellipsizer.js: Text ellipsizing with tooltip integration
- svg-overlay-manager.js: Main coordinator orchestrating all functionality

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
4d5fa1c43b dots-viewer: make pipeline dot references clickable for navigation
When GStreamer pipeline graphs contain references to other pipeline dot files,
users should be able to navigate between related pipeline views by clicking
on these references. This enables exploring complex pipeline hierarchies
where one pipeline references sub-pipelines.

The implementation detects text elements containing pipeline-dot references,
styles them as web links, and handles click events to navigate to the
referenced pipeline while preserving existing text selection and drag
functionality for other elements.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
28684cba1a dots-viewer: Make text copyable while preserving drag functionality
Enable text selection on SVG text elements by changing CSS user-select
properties from 'none' to 'text' and cursor from 'default' to 'text'.

Add JavaScript event handling to intercept mousedown events on text
elements, preventing dragscroll interference while allowing normal text
selection. This preserves the existing drag-to-pan functionality for
non-text areas while making text elements selectable and copyable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Olivier Crête
e37d5b7b74 rtpbasedepayload: Avoid potential use-after free
Clear the pointer after freeing the reference.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9579>
2025-08-19 09:15:03 -04:00
Havard Graff
162c4b0008 buffer: Fix gst_buffer_memcmp() / gst_buffer_memset() using wrong memory index
Regression from 160205b483dc7a1ae5da60d80a722837cf7c01d0.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9565>
2025-08-19 08:18:17 +00:00
Vivian LEE
c4439a5b55 adaptivedemux2: fix crash due to log
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4588

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9573>
2025-08-19 07:20:13 +00:00
Thibault Saunier
48a2be6d6a validate: http-actions: Replace GUri with GstURI for GLib 2.64 compatibility
GUri was added in GLib 2.66, but GStreamer claims to build with 2.64.
Replace GUri usage with equivalent GstURI functions to maintain
backward compatibility.

Fixes #4607

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9572>
2025-08-19 06:49:41 +00:00
Víctor Manuel Jáquez Leal
c63d3b5cb4 tests: fix queues for vulkan h26x encoders
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9571>
2025-08-18 19:46:26 +02:00
Sebastian Dröge
b051285e03 python: Handle buffer PTS/DTS/duration/offset/offset-end as unsigned long long
Previously these fields were truncated to 32 bits on 32 bit platforms and
64 bit Windows because of using `unsigned long`.

Thanks to Tim Williams for reporting and debugging this issue.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4603

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9567>
2025-08-18 15:43:50 +00:00
Jan Alexander Steffens (heftig)
e40a037b67 decodebin3: Update stream tags
parsebin does this, so should decodebin3.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9557>
2025-08-18 09:43:39 +00:00
Sebastian Dröge
58a48d92bb value: Consider NULL caps in array a fixed value
There's no requirement for caps in arrays to be non-NULL and NULL is clearly a
fixed, single value.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9522>
2025-08-18 09:05:36 +00:00
Víctor Manuel Jáquez Leal
c1d0fb0165 vulkanh26xdec: fix debug category name
This is a regression from merge request !78011

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9560>
2025-08-16 16:33:14 +00:00
Víctor Manuel Jáquez Leal
9c93152599 vulkanh26xdec: re-negotiate after FLUSH
Vulkan decoders also have the same issue as VA decoders fixed in !9457, where
FLUSH event doesn't renegotiate downstream the pipeline.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9560>
2025-08-16 16:33:14 +00:00
Víctor Manuel Jáquez Leal
101722d477 vkimagebufferpool: support video profile independent images
With video_maintenance1 extension is possible to create images independent of a
the video profile list, under that image will be processed.

With that extension is possible to share the same image for dynamic transcoding.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9550>
2025-08-16 15:36:02 +02:00
Adrian Perez de Castro
2ebb835381 alsa: Fill in alsa.name for PCM sinks
The device description may be used as the "alsa.name" property, to match
what is done for card devices.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9534>
2025-08-15 20:54:16 +00:00
Adrian Perez de Castro
aae0ed6eb2 alsa: Enumerate output-only PCM sinks
Change the logic to skip only devices which have "Input" as their IOID. The ALSA
Input/Output identifier (IOID) it may be either "Input", "Output", or NULL; with
the latter meaning that the device supports both input and output.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9534>
2025-08-15 20:54:16 +00:00
Jan Alexander Steffens (heftig)
fbe7a86973 tests: cccombiner: Test durationless buffers
Crashes without the previous fix.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9415>
2025-08-15 00:12:03 +00:00
Jan Alexander Steffens (heftig)
69ddd8c3c7 cccombiner: Don't crash when first frame has no duration
Aggregate again so the code above can determine the end time or EOS.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9415>
2025-08-15 00:12:03 +00:00
Jan Alexander Steffens (heftig)
1428a86783 cccombiner: Avoid dividing by zero framerate
This was broken in b29262e662b86cd76225894f7504ee505125fa49.

The `gst_util_uint64_scale` emitted a critical warning and returned
`GST_CLOCK_TIME_NONE`, so beyond removing the warning this fix does not
change behavior.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9415>
2025-08-15 00:12:03 +00:00
Adrian Perez de Castro
71619ec72b oss: Check for element types when reconfiguring
Make gst_oss_device_reconfigure_element() check whether the passed element
type matches that of the device itself before attempting to apply the new
configuration.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9558>
2025-08-14 23:54:33 +03:00
Adrian Perez de Castro
9c166d6dfa alsa: Check for element types when reconfiguring
Make gst_alsa_device_reconfigure_element() check whether the passed element
type matches that of the device itself before attempting to apply the new
configuration.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9558>
2025-08-14 21:44:59 +03:00
Seungha Yang
7a48a0036f wasapi2: Warm up capture audio client on open
If the endpoint is idle, the first IAudioClient::Start() call
may take a long time to return. Start/stop the capture client
on open to reduce latency of subsequent Start() calls.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9553>
2025-08-14 12:38:41 +00:00
Seungha Yang
cb7dcff69e wasapi2sink: Do not push too large preroll buffer to endpoint
To avoid startup glitches, a silent buffer is pushed to
render endpoint, but pushing too large silent buffer will
introduce unnecessary latency. Limit it to a single period worth data.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9553>
2025-08-14 12:38:41 +00:00
Víctor Manuel Jáquez Leal
71b787a39f vkdecoder-private: fix mistake from !9531
This was a very silent mistake.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9552>
2025-08-13 19:59:52 +02:00