Commit graph

4240 commits

Author SHA1 Message Date
Thibault Saunier
04e9660c26 cargo_wrapper: Reindent and cleanup
This commit should go into a new .git-blame-ignore-revs file when we have the
final hash

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2471>
2025-08-20 06:51:33 +00:00
Tim-Philipp Müller
01b8303b5c threadshare: blocking_adapter: fix Since marker in docs
Should be 0.14.2 since it has been backported to the 0.14 branch.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2479>
2025-08-20 06:21:17 +00:00
François Laignel
829cc21696 threadshare: inter: update doc example
Use recent improvements:

* `ts-audiotestsrc` can now be used properly.
* `ts-blocking-adapter` must be used before a blocking element.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2477>
2025-08-19 16:49:24 +02:00
François Laignel
243a8a93ea threadshare: have Task log its obj
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2476>
2025-08-19 13:38:51 +02:00
Sebastian Dröge
a005cf8e05 fallbacksrc: Don't keep CustomSource state locked while adding/removing pads
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2474>
2025-08-18 13:08:07 +03:00
Sebastian Dröge
6fb729d771 fallbacksrc: Don't lock CustomSource state lock twice when exposing pads
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2474>
2025-08-18 13:07:51 +03:00
Thibault Saunier
90cc117095 ci: Re enable skia as https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/692 was fixed
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2472>
2025-08-14 22:39:51 -04:00
Sanchayan Maity
3e291611b2 Update docs for hlssink3 plugin to include single media file property
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 20:02:14 +05:30
Sanchayan Maity
bd30823dbb hlssink3: Add fmp4 plugin as a dependency for hlscmafsink tests
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 20:02:14 +05:30
Sanchayan Maity
1f68cf4f44 hlssink3/hlscmafsink: Make GioOutputStream a sub-class of OutputStream
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 20:02:14 +05:30
Sanchayan Maity
917e1f5885 hlssink3/hlscmafsink: Add test for validating non-overlapping byte range
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 20:02:14 +05:30
Sanchayan Maity
a8684853d0 hlssink3/hlscmafsink: Add byte range tag information to hls-segment-added message
While at it, for tests, replace unreachable!() with panic!() and print
the error message contents.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 20:02:14 +05:30
Sanchayan Maity
efbfab76bc hlssink3/hlscmafsink: Add tests for single media file
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 19:24:50 +05:30
Sanchayan Maity
2539a59b99 hlssink3/hlscmafsink: Support the use of a single media file
Allow the use of a single file for media. Media playlist will use byte
range tags like below while referencing the same single media file.

```
#EXT-X-PLAYLIST-TYPE:VOD
#EXT-X-MAP:URI="main.mp4",BYTERANGE="768@0"
#EXT-X-BYTERANGE:198120@768
#EXTINF:10,
main.mp4
#EXT-X-BYTERANGE:197426@198888
#EXTINF:10,
main.mp4
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2439>
2025-08-14 19:24:50 +05:30
François Laignel
8ec5d0995f rtprecv: fix race condition on first buffer
When an incoming buffer is received, a deadlock can occur if:

1. 1st buffer is currently being handled by the src pad's task
   => holds semaphore.
2. 1st buffer reaches downstream AudioDecoder => Latency query.
3. src pad's task still holding semaphore while relaying Latency query.
4. `src_query()` calls `Pad::default()` which calls `iterate_internal_links()`.
5. `iterate_internal_links()` tries to acquire the `state` `Mutex` which is
   already locked  by `handle_push_jitterbuffer()`.

This commit temporarily releases the `state` `Mutex` until the semaphore is
acquired.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2466>
2025-08-13 18:20:23 +00:00
François Laignel
e4e14cf5ca threadshare: intersink: return from blocking tasks when stopping
This commit cancels blocking tasks when the element is requested to stop.
This is to prevent deadlocks.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2465>
2025-08-13 17:47:18 +00:00
François Laignel
458e59979f threadshare: inter: store upstream latency in InterContext
... instead of retrieving the element following the sink pad.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2465>
2025-08-13 17:47:18 +00:00
François Laignel
c9334b218f threadshare: add a blocking adapter element
When a threadshare element streams buffers to an element which synchronizes on
the clock or which uses a limited blocking queue, the threadshare context is
perdiodically blocked, preventing other async tasks from progressing.

One workaround is to use a regular `queue` with enough buffering to cope with
early buffers. This is suboptimal though because this `queue` doesn't propagate
backpressure upstream.

The `ts-blocking-adapter` applies an async backpressure when downstream blocks,
allowing the threadshare context to process other tasks. This is achieved by
having the 'sink' Pad forward serialized items (buffers, ...) to the 'src' Pad
Task (thread) via a rendezvous channel.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2427>
2025-08-13 17:04:54 +00:00
Sebastian Dröge
61578518d4 transcriberbin: Fix settings/state lock order violation in set_property()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2463>
2025-08-13 13:57:35 +03:00
Sebastian Dröge
9710476c96 transcriberbin: Don't keep state locked while querying upstream latency
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2463>
2025-08-13 13:57:17 +03:00
François Laignel
357336cd56 threadshare: audiotestsrc: fix setting samples-per-buffer...
... by not locking `settings` twice.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2461>
2025-08-12 12:49:31 +02:00
Mathieu Duponchelle
75e2582802 tttocea708/translate: improve logic for prepending spaces
No space needs to be prepended after inserting a carriage return or
clearing the screen.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2345>
2025-08-11 18:21:55 +00:00
Mathieu Duponchelle
4ad8295ae3 tttocea708: implement the same behavior as tttocea608 on speaker change
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2345>
2025-08-11 18:21:55 +00:00
Mathieu Duponchelle
db8d0e90c9 tttocea608: expose speaker-prefix property
When set, the value will be used to prefix the new line when outputting
a carriage return after a speaker change in roll-up mode.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2345>
2025-08-11 18:21:55 +00:00
Thibault Saunier
abc5cf7303 rtpgccbwe: avoid clamp() panic when min_bitrate > max_bitrate
Prevent calling clamp() with invalid bounds where min > max, which would
cause a panic with "assertion failed: min <= max". This panic would poison
the mutex lock, causing all subsequent lock().unwrap() calls to fail with
PoisonError.

This can happen when min-bitrate and max-bitrate properties are set
individually, creating a temporary inconsistent state between the values.

Fix by validating the bitrate range before calling clamp() and using
max_bitrate for both bounds when min > max to ensure safe operation.
Use LogContext to log the error only once per unique invalid pair.

Fixes #711

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2456>
2025-08-11 11:29:11 -04:00
Sebastian Dröge
2336688c8a fallbacksrc: Don't restart source if the element is just being shut down
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2455>
2025-08-11 16:40:37 +03:00
Seungha Yang
ef3c03074a aws: Ensure task stopping on paused-to-ready state change
Disconnect channel so that srcpad task can stop immediately

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2440>
2025-08-11 11:59:52 +00:00
Sebastian Dröge
a41a6954fc fallbacksrc: Don't panic during retries if the element was shut down in parallel
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2451>
2025-08-11 14:30:42 +03:00
Sebastian Dröge
9861f682e6 s302mparse: Add new S302M audio parser
This extracts metadata from an S302M audio stream and interpolates PTS
as needed, but still requires a properly packetized stream from
upstream.

Parsing S302M without packetization is not easily possible because of
the lack of synchronization markers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2435>
2025-08-11 08:33:18 +00:00
Sebastian Dröge
8270a44192 Update CHANGELOG.md for 0.14.1 2025-08-10 22:06:30 +03:00
Sebastian Dröge
512f655b1d Update Cargo.lock
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2448>
2025-08-10 11:39:40 +00:00
Sebastian Dröge
d1b2c3a2e9 Update to async-tungstenite 0.31
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2448>
2025-08-10 11:39:40 +00:00
Tim-Philipp Müller
ece7013e71 README: add missing plugins
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2443>
2025-08-10 09:26:31 +00:00
Tim-Philipp Müller
9ac981b731 ci: add script to check README against plugins list
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2443>
2025-08-10 09:26:31 +00:00
Sebastian Dröge
e52dedcf38 analytics: Ignore some tests that fail due to core changes until fixed
See https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2444
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9522

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2442>
2025-08-10 09:31:29 +03:00
Sebastian Dröge
97ed00c8cd docs: Update plugins cache
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2442>
2025-08-08 17:12:56 +03:00
Sebastian Dröge
860b8fc241 Don't suggest running cargo cinstall after cargo cbuild
That will build everything twice as `cargo cbuild` builds with the dev
profile by default and `cargo cinstall` uses the release profile.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2442>
2025-08-08 16:48:51 +03:00
Sebastian Dröge
a8be57a742 Fix various new clippy 1.89 warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2436>
2025-08-07 12:26:54 +00:00
Thibault Saunier
4e7d42c16e tracers: pipeline-snapshot: reduce WebSocket connection log level
Change WebSocket connection failure log from warning to debug level as
these retries are expected behavior and don't indicate an error condition.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2433>
2025-08-06 10:41:51 -04:00
Sebastian Dröge
aa4d9333b9 threadshare: Also enable windows Win32_Networking_WinSock feature
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2431>
2025-08-06 11:09:59 +00:00
François Laignel
fe4e355b9e webrtc: android example: remove videoconvert
The `glimagesink` can handle video conversion just fine, we don't need to use
a `videoconvert` in that branch.

This commit also moves the `handle_media_stream()` branches within
`on_incoming_stream()` as the factorization is no longer justified.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2216>
2025-08-06 10:42:36 +00:00
François Laignel
6ef4a8de4c webrtc: android example: fix media handling initialization sequence
The way media handling was implemented was suboptimal:

* The media elements were linked after being synchronized with their parent.
  Any initial queries would fail.
* The window handle was initialized after the video elements were linked and
  synchronized with their parent. It was not available at GL context creation,
  but assigned afterwards.

This commit fixes the above. The behaviour is unchanged, but it makes more sense
in my opinion.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2216>
2025-08-06 10:42:36 +00:00
François Laignel
dccdda96b6 threadshare: queue & proxy: fix race condition stopping
When stopping `ts-queue` & `ts-proxysink`, the pending queue is removed. There
is a short period of time when a buffer can be handled after the pending queue
is removed but before the element is actually stopped. Since the dataqueue no
longer accepts buffers and the pending queue is removed, a new pending queue was
created and the element was set to wait for queue space.

The stopping procedure is handled with `last_res` `Mutex` locked and set to
`Flushing`.

This commit adds a check to `last_res` before creating a new pending queue and
aborts if the element is `Flushing`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2428>
2025-08-06 08:26:04 +00:00
Sebastian Dröge
b61d790081 threadshare: Enable windows Win32_Networking feature
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2420>
2025-08-06 07:30:08 +00:00
Mathieu Duponchelle
0578eb49cf awstranslate: expose property for turning brevity on
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2406>
2025-08-05 15:08:10 +00:00
Seungha Yang
e314b2e591 awstranslate: Handle multiple stream-start event
Do not spawn new task loop with channel if we have one already

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2404>
2025-08-05 14:26:38 +00:00
Seungha Yang
00b7ebab48 awstranscriber2: Handle multiple stream-start event
Do not spawn new task loop with channel if we have one already.
The same change as 731ceb58bd
for awstranscriber2

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2404>
2025-08-05 14:26:38 +00:00
Mathieu Duponchelle
47a3d4a37f speechmatics: expose mask-profanities property
When enabled, words tagged as profanities are replaced with an
equal-sized amount of "*"

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2344>
2025-08-05 11:46:22 +00:00
Taruntej Kanakamalla
4e2c16a2af Revert "threadshare: udp: avoid getifaddrs in android"
This reverts commit 75a0baa6fa.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1918>
2025-08-05 11:20:06 +00:00
Xavier Claessens
78c8d4df55 webrtcsink: Move videorate before videoconvert and videoscale
Since videorate has drop-only=true, this could reduce the number of
frames to convert and scale.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2402>
2025-08-05 10:56:54 +00:00