121924 Commits

Author SHA1 Message Date
Marc Leeman
f2b5c0b602 meson.build: test for and link against libatomic if it exists
It's needed on some platforms for some subset (or all) atomic operations and
checking for the cases when it's actually needed is quite complex.

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8637>
2025-03-14 15:12:33 +00:00
Thibault Saunier
e845b596a2 validate: baseclasses: Reset Test.extra_logfiles when copying to start an iteration
Otherwise we get a big mixup with all iteration pointing to all the extra_logfiles

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8640>
2025-03-14 12:50:34 +00:00
Branko Subasic
2f2b19be83 tracer: Make it compile when tracer hooks are disabled
The GST_TRACER_POOL_BUFFER_(DE)QUEUED macros used when tracer hooks are
disabled took only one argument, causing compile errors when building
with tracer hooks disabled.

Change-Id: I0958c0b018f1fc4a6d84ab0bdd9e42895ae1fe77
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8638>
2025-03-14 11:07:03 +00:00
Piotr Brzeziński
ad6c5b05e9 vtenc: Reset restart flag when creating session in set_format()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8597>
2025-03-14 10:12:38 +00:00
Piotr Brzeziński
f7fe817c87 vtenc: Avoid deadlocking when changing properties on the fly
VT supports changing properties on the fly, and old code attempted to
support that. Perhaps 10 years ago that worked, but these days
VTSessionSetProperty will always wait for the output callback to finish
before proceeding. This means that it's very prone to deadlocking, as
property setters will take the object lock, the callback thread will
take the stream lock, and the main (streaming) thread attempts to take
both, resulting in a deadlock.

New version uses something similar to other encoders (e.g. x264enc) -
changing a property when a session is already created will just flag it
to be reconfigured upon the next encode call. This is done in similar
fashion to how restarting the session upon an error works.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8597>
2025-03-14 10:12:38 +00:00
Edward Hervey
235b0acd63 decodebin3: Don't avoid parsebin even if we have a matching decoder
This is too brittle, there is no guarantee that the input stream has been
properly parsed.

There is another check above (is_input_parsed) that will skip that if the
content came from `urisourcebin` and had a parser applied

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8641>
2025-03-14 09:40:35 +01:00
Alyssa Ross
dd1fc2b793 v4l2object: fix type mismatch when ioctl takes int
v4l2object->ioctl can either be set to v4l2_ioctl() or ioctl().
v4l2_ioctl() always takes the request number as unsigned long int, but ioctl()
may take (at least) unsigned long int, int, or unsigned, depending on libc.
This means that there isn't one function pointer type that can be used for
v4l2object->ioctl that will always be able to accomodate being set to either of
v4l2_ioctl() and ioctl().  It's therefore necessary to wrap one of them so that
both options can have the same type.  This fixes an assignment from incompatible
pointer type error when building for musl.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8613>
2025-03-13 18:26:08 +00:00
Tim-Philipp Müller
b3dd34cfa0 ci: disable gtk4 build by default
It's not used by anything in the monorepo, only used when
rebuilding the gstreamer-rs image (used by gst-plugins-rs
where the gtk4 plugin lives).

Doesn't make sense to build all of gtk4 on every CI run that
touches the relevant files just to make sure it still works
for the image rebuild, and it's a problem for users with long
filenames (such as `gstreamer-backport-bot`) where the pipeline
will simply not pass because the gtk glib-mkenums command line
length exceeds 32767 characters.

Better to set up a scheduled pipeline for that.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8636>
2025-03-13 15:06:00 +01:00
Tim-Philipp Müller
46674ac501 cairo: update to 1.18.4
Update to wrapdb version with fallback uri once that exists.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8627>
2025-03-13 11:37:35 +00:00
Tim-Philipp Müller
327926c013 ffmpeg: update wrap to 7.1.1
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8627>
2025-03-13 11:37:35 +00:00
Víctor Manuel Jáquez Leal
2172b4ab9f va: remove unused headers
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8626>
2025-03-13 10:02:05 +00:00
Sebastian Dröge
58c6b67dbd examples: webrtc: rust: Fix a couple of new clippy warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8625>
2025-03-13 08:32:49 +00:00
Sebastian Dröge
48cec32341 examples: webrtc: rust: Update dependencies
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8625>
2025-03-13 08:32:49 +00:00
Olivier Blin
9b47a2dde3 alsadeviceprovider: Fix leak of Alsa longname
Detected by ASan.

As a drive-by fix, use free() instead of g_free() in gstalsadeviceprovider.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8619>
2025-03-13 01:01:39 +00:00
Tim-Philipp Müller
bd3aabbc25 videorate: add support for JPEG-XS
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8601>
2025-03-13 00:11:52 +00:00
Tim-Philipp Müller
7861a2e4fb imagefreeze: add support for JPEG-XS
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8601>
2025-03-13 00:11:52 +00:00
Sebastian Dröge
5b1f7ef803 devtools: dots-viewer: Update dependencies and make windows dependencies conditional
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8624>
2025-03-12 21:48:33 +00:00
Jordan Petridis
1747b5fa73 Revert "ci: Add rules:changes:compare_to to the job rules"
This reverts commit dcd11f0a104964f7fc02c38104ed57fd0aa794a2.

In dcd11f0a104964f7fc02c38104ed57fd0aa794a2 we started making use
of gitlab's changes:compare_to in hopes of addressing #3780

However compare_to seems to have different behavior based on:

* The type of the branch
* If the repo is a fork or not
* If the pipeline is a branch or MR pipeline
* If the commit is force pushed or not
* If the pipeline is associated with a "push" event,
  * Manual and scheduled pipelines are not.

If we leave compare_to underfined and to its default value,
it causes issues with branch pipelines, as:

* If you push a new branch, it doesn't have anything to compare
against and changes: either will trigger or not, depending on the
gitlab version

* If you push to an existing branch, it only compares against the
previous commit.

* if you force push to a branch, it doesn't work at all it seems. [1]

Thankfully for merge request pipelines, it always seems to compare
against the Merge Request Target tree. But also if there is a Merge
Request open, and the value of compare_to isn't defined (say if it's a
force push or it's the first branch pipeline of the branch) it will
fallback to using the tree from the Merge Request Target, making it even
more confusing.

But if we try to overide it to fix the behavior for branches, we end up
breaking merge request. There seems to be a bug in gitlab (unclear if
its intended or not) where if you have access to the upstream
repository, gitlab will compaee_to against that in the MR pipeleine, but
otherwise it will try to compare against your fork's branch which will
certainly be outdated. Additionally it didn't seem to error out if the
branch specified doesn't exist only in one of the two places so its very
hard to reverse engineer the behavior.

[1] https://gitlab.com/gitlab-org/gitlab/-/issues/349694

Long story short, this is way more complicated than its worth, and has
caused a lot of issues since it was introduced. Revert the change and
try again another time.

Related https://gitlab.com/gitlab-org/gitlab/-/issues/389808

Close #3965

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8563>
2025-03-12 20:46:23 +00:00
Philippe Normand
1e2b103b20 alphacombine: De-couple flush-start/stop events handling
There is no guarantee that any FLUSH_STOP event is preceded by a FLUSH_START.
The element now stops flushing once it has received a FLUSH_STOP on all its sink
pads.

Fixes #4174

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8604>
2025-03-12 18:34:53 +00:00
Edward Hervey
6454698f82 urisourcebin: Make parsebin activation more reliable
`parsebin` is potentially added by a `typefind` callback.

That `typefind` was activated by a `READY_TO_PAUSED` state change on `urisourcebin`

We want to ensure that it is the "setup_parsebin_for_slot" method that activates
the underlying `parsebin`, and not the external state-change.

Otherwise we would risk a potential deadlock where elements activating in
`parsebin`, and which would cause the upstream `typefind` to switch scheduling
mode, would not be able to acquire the STREAM_LOCK of the `typefind` task.

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8511>
2025-03-12 16:15:20 +00:00
Thibault Saunier
ed693c7435 video: Give better names to buffer pools
Making debugging simpler

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8617>
2025-03-12 14:49:22 +00:00
Thibault Saunier
9979936703 tracer: Add a hook to track when buffers are queued/dequeued in pools
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8617>
2025-03-12 14:49:22 +00:00
Tim-Philipp Müller
1a971d8e12 Back to development in main branch after 1.26.0
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8621>
2025-03-12 14:21:08 +01:00
Tim-Philipp Müller
d31ce8e5e1 Release 1.26.0 2025-03-11 20:20:16 +00:00
Alyssa Ross
bfd995f9df tcpclientsrc, tcpserversrc: fix building for musl
musl only exposes struct tcp_info when _GNU_SOURCE is defined.

Fixes: b4bef7fd35 ("tcpclientsrc, tcpserversrc: fix tcp stats gathering")
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8612>
2025-03-11 12:43:55 +01:00
Ruben Gonzalez
7b98c739c8 vacompositor: Add missing GST_VIDEO_CROP_META_API_TYPE
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8537>
2025-03-10 16:39:00 +00:00
Carlo Caione
69c1746139 uvcgadget: Properly implement GET_INFO control responses
According to the UVC 1.5 specification, section 4.1.2, the GET_INFO request
must return a bitmap indicating supported operations for the control.
Value 0x00 indicates that neither GET nor SET operations are supported.

This patch fixes control handling in the UVC gadget implementation to properly
respond to GET_INFO requests with the correct bitmap, allowing host systems
to properly detect supported control operations (none in this case).

The pipeline I'm using to test this is:

  gst-launch-1.0 videotestsrc ! uvcsink v4l2sink::device=/dev/video0

This is the equivalent of [0] but the difference is that we are now returning
0x00 instead of 0x03.

Without this change the host in my case is unable to probe the UVC gadget at
all, automatically disconnecting the device after a few seconds.

Following is the log when the gadget is not working (without this fix):

  usb 1-1.2: new high-speed USB device number 73 using xhci_hcd
  usb 1-1.2: New USB device found, idVendor=0525, idProduct=a4a2, bcdDevice= 5.15
  usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
  usb 1-1.2: Product: UVC Gadget
  usb 1-1.2: Manufacturer: localhost.localdomain
  usb 1-1.2: SerialNumber: 0123456789
  usb 1-1.2: Found UVC 1.10 device UVC Gadget (0525:a4a2)
  usb 1-1.2: Failed to query (GET_INFO) UVC control 2 on unit 1: -110 (exp. 1).
  usb 1-1.2: UVC non compliance - GET_DEF(PROBE) not supported. Enabling workaround.
  uvcvideo 1-1.2:1.1: Failed to query (129) UVC probe control : -71 (exp. 34).
  uvcvideo 1-1.2:1.1: Failed to initialize the device (-71).
  cdc_subset 1-1.2:1.0: probe with driver cdc_subset failed with error -22
  cdc_subset 1-1.2:1.1: probe with driver cdc_subset failed with error -22
  usb 1-1.2: USB disconnect, device number 73

With the fix the USB device is correctly probed:

  usb 1-1.2: new high-speed USB device number 88 using xhci_hcd
  usb 1-1.2: New USB device found, idVendor=0525, idProduct=a4a2, bcdDevice= 5.15
  usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
  usb 1-1.2: Product: UVC Gadget
  usb 1-1.2: Manufacturer: localhost.localdomain
  usb 1-1.2: SerialNumber: 0123456789
  usb 1-1.2: Found UVC 1.10 device UVC Gadget (0525:a4a2)

[0] camera/uvc-gadget@0df9d3ad

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8572>
2025-03-07 10:12:25 +01:00
Benjamin Gaignard
cb681d8d28 v4l2codecs: Fix caps leak after sorting caps
gst_v4l2_format_sort_caps() create a new caps which need to be
release to avoid leak.

Co-authored-by: Robert Mader <robert.mader@posteo.de>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8583>
2025-03-06 21:28:33 +00:00
Benjamin Gaignard
95a3c0123f v4l2codecs: Release sink allocator when deciding allocation
All decoders have the same design pattern in decide allocation
and forgot to release sink allocator before allocating a new one.
Fixing the memory leak by clearing sink allocator before creating
the new one.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8583>
2025-03-06 21:28:33 +00:00
Benjamin Gaignard
0d1cc08176 v4l2codecs: allocator: Fix buffers leak when using remove buffers
When removing buffers from v4l2 queue do not forget to release
the memory on gstreamer side.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8583>
2025-03-06 21:28:33 +00:00
Hou Qi
ba6c86fc4d v4l2: object: Not consider GRAY as RGB
This is to fix colorimetry mismatch between v4l2object and video-info
when format is GRAY.

Fixes #4270

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8590>
2025-03-06 20:40:03 +00:00
Seungha Yang
dba3bdd0cf h264ccextractor,h265ccextractor: Do not resend caps per output buffer
Send caps event only when it's required

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4281
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8596>
2025-03-06 16:24:44 +00:00
Devon Sookhoo
2f2a6e76bc qtdemux: InterleaveType enum
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8578>
2025-03-06 14:40:45 +00:00
dukesook
ee9c8724c3 qtdemux: component to format lookup table
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8578>
2025-03-06 14:40:45 +00:00
Pablo García
af148bb746 curl: replace #if with #ifdef (part 2)
Continuation of 47d1262402c81a9054e618052deeff7414b4f75d, that is not enough.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8595>
2025-03-06 13:44:33 +00:00
Stéphane Cerveau
93364189d0 vulkan/operation: fix timeline semaphore extension detection
As for synchronization2, the timeline semaphore has been
been promoted in 1.2 and does not have to be enabled explicitely.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
b9bbcf9202 vulkan/operation: fix synchronization2 extension detection
The synchronization2 extension is a core part of Vulkan 1.3.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
20eb11e5c4 ci: update ABI for vulkan change
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
e23bc6ed77 vulkan/device: only enable relevant extensions
Extensions can have a minimum set of dependencies (e.g. API version) and may
also be promoted to core in a later version.  Don't explicitly enable extensions
that fail to meet their requirements or that have been promoted to the core API.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
e7b8ac099f vulkan/operation: retrieve function pointers directly from the device
The instance API version supported may not be of the same version supported by
the device. It is possible that the function that is returned may be non-0
but not functional due to the requested API version of the instance limiting the
availability of calling the returned function.

Can be reproduced by running a pipeline with GST_VULKAN_INSTANCE_API_VERSION=1.1

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
7452589ff8 vulkan/instance: allow the requested api version to be larger than the supported
Since Vulkan 1.1, the requested API version is the maximum API version that the
application is expecting to use. It is also possible for individual devices
(backed by potentially different drivers) may support a higher or lower API
version than the instance.  Both cases (higher and lower) should be supported
and as such, it is not an error to request an API version that is larger than
the instance supported API version.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:21 +00:00
Matthew Waters
156b05d52b vulkan: plugin: add debug for why an instance fails to open
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:20 +00:00
Matthew Waters
4692a45dea vkformat: fix format_from_video_info_2 to actually runtime check versions and extensions
If the vulkan plugin was compiled against a newer version than the supported
vulkan runtime instance or device, then it was possible for format retrieval to
fail.  Failure was due to unconditionally using newer extensions and features
without runtime checking them.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:20 +00:00
Matthew Waters
51dda24a88 vulkan: fix device related API version checks
The API version exposed by a particular device can be completely different from
what is exported by the parent instance.  Since Vulkan 1.1 it is also possible
to use newer device API than supported by the instance API version (with the
appropriate version checks).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:20 +00:00
Matthew Waters
72860a20bf vulkan/physicaldevice: add methods for retrieving and checking against an API version
Most version checks should actually be done against the device API version and
not the instance API version.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8554>
2025-03-06 12:14:20 +00:00
Pablo García
3e8fbc1203 curl: replace #if with #ifdef
Using #if instead of #ifdef was causing some issues when cross-compiling, like:

        ../ext/curl/gstcurlsmtpsink.c:54:5: error: "HAVE_SYS_SOCKET_H" is not
        defined, evaluates to 0 [-Werror=undef]
        54 | #if HAVE_SYS_SOCKET_H

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8589>
2025-03-05 15:13:43 +01:00
Pablo García
4640650ff5 curl: remove unnecesary reference to unistd.h
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8589>
2025-03-05 15:13:35 +01:00
Christopher Degawa
6bdfaa4606 svtav1enc: update to use SVT-AV1 3.0.0 API changes
Signed-off-by: Christopher Degawa <ccom@randomderp.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8539>
2025-03-05 13:18:26 +00:00
Jakub Adam
1248e4c462 adaptivedemux2: wake waiting streams upon completed manifest downlaod
Fixes race when a live stream finishes playing all segments from a
dynamic manifest and waits for its update. If the manifest meanwhile
changes from dynamic to static and this update is received
asynchronously, periodic calls of gst_adaptive_demux_manifest_update_cb
will stop. As a result the blocked stream won't get notified about the
updated manifest and will remain stuck indefinitely.

Also removed the wake-up code from gst_adaptive_demux_manifest_update_cb
where it remained as a relic from previous implementation when manifest
updates were synchronous.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8587>
2025-03-05 11:37:26 +00:00
Branko Subasic
f37b820060 voamrwbenc: Do not install anything unless dependency found
If the dependency for the plugin is not found then nothing should be
installed, neither the element nor documentation.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8586>
2025-03-05 10:48:40 +00:00