Commit graph

3739 commits

Author SHA1 Message Date
Tim-Philipp Müller
b0aa32b844 Update versions for 0.22.8
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1561>
2024-10-18 10:39:57 +00:00
Tim-Philipp Müller
523f7f5be4 Update CHANGELOG.md for 0.22.8
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1561>
2024-10-18 10:39:57 +00:00
Viktor Chvatal
f5d372769e gstreamer: Fix binding to wrong C function in PadExtManual::proxy_query_caps
Fixes #533

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1558>
2024-10-17 13:40:16 +00:00
Daniel Stone
0893fb8999 ci: Only use as many cores as we're supposed to
Instead of spawning 64 compiler instances on a 64-core machine that's
being shared with 7 other jobs.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1546>
2024-09-21 00:28:35 +02:00
L. E. Segovia
50c85f8aea Add workaround for linking against macOS SDK's relocatable dylibs
See https://github.com/rust-lang/cargo/issues/5077#issuecomment-1284482987
and https://github.com/rust-lang/rust/issues/127100

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1540>
2024-09-20 07:18:00 +00:00
François Laignel
590338bb43 gst: fix typo in format doc
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1536>
2024-09-20 06:51:04 +00:00
Sebastian Dröge
2ebd401de6 video: Add #[must_use] attribute to VideoTimeCode::add_interval()
It doesn't change the original value but returns the new result.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1541>
2024-09-19 11:48:46 +00:00
Albert Sjolund
cabad5890c utils: streamproducer: wrap atomic operations
In order to support more platforms, especially MIPS,
add a small wrapper for necessary atomic(u64) instructions.
It exposes the necessary functions, and falls back to
mutex if needed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1539>
2024-09-19 12:54:23 +02:00
François Laignel
34b97e21a4 tags: fix index() lifetime bind
The signature for `TagListRef::index` didn't bind the lifetime of the returned
`TagValue` to `&self`. This causes the following code to compile:

```rust
 1 let title = {
 2     let mut tags = TagList::new();
 3     {
 4         let tags = tags.get_mut().unwrap();
 5         tags.add::<Title>(&"some title", TagMergeMode::Append);
 6     }
 7
 8     let title = tags.index::<Title>(0).unwrap();
 9     assert_eq!(title.get(), "some title");
10
11     title
12 };
13
14 assert_eq!(title.get(), "some title");
```

... but it panics at runtime on the last `title.get()`:

```
Invalid tag type: WrongValueType(ValueTypeMismatchError
    { actual: <invalid>, requested: gchararray })
```

Indeed, the `title` `TagValue` is freed with the `tags` on line 12.

This commit fixes the function signature so the returned `TagValue` can't
outlive its `TagListRef`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1523>
2024-09-11 15:25:27 +02:00
François Laignel
739de84a6b gst: anticipate GQuark to GstIdStr lifetime changes
GStreamer fixes a memory leak due to GQuarks by switching to GstIdStr.
The consequence is that strings previously backed by a GQuark returned by a
function will now get their lifetime bound to that of its owner, while the
GQuark version ensured static lifetime.

Because some functions return a string with the assumption that they are static
and because we can't alter the API for existing versions of the bindings, this
MR temporarily forces affected strings as GQuarks, thus gaining static lifetime
regardless of the GStreamer version actually being used.

For newer versions of the bindings, the API will be fixed and GQuarks will be
removed in favor a leakless solution.

See: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7432
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1521>
2024-09-11 12:57:30 +02:00
Sebastian Dröge
a9f94b9088 Update Cargo.lock
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1498>
2024-08-13 14:41:56 +03:00
Guillaume Desmottes
a7a6229718 utils: streamproducer: fix set_forward_events() doc
The events are forwarded from the appsink to the appsrcs.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1492>
2024-08-05 09:41:47 +01:00
Tim-Philipp Müller
da8c41c6fb Update CHANGELOG.md for 0.22.7
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1487>
2024-07-24 13:21:24 +01:00
Tim-Philipp Müller
dc4dfca5c4 Update versions to 0.22.7
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1487>
2024-07-24 11:29:39 +01:00
Sebastian Dröge
ce6741a157 gstreamer: meta: Pass an empty tag array instead of NULL to gst_meta_register_custom()
NULL gives a critical warning but an empty, NULL-terminated array gives
the desired result.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/issues/516

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1485>
2024-07-18 20:51:07 +01:00
Sebastian Dröge
1ff88815df gstreamer: Unconditionally use gst_parse_context_copy()
It's available since 1.12.1 and the minimum supported version for the
bindings is 1.14 nowadays.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1479>
2024-07-06 13:04:31 +01:00
Thibault Saunier
38962830d9 ges: Add setters to FrameCompositionMeta
Some elements might need to modify them

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1476>
2024-07-03 12:01:12 +01:00
Sebastian Dröge
e46927057b gstreamer: childproxy: Include child property name in error message when lookup fails
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1474>
2024-06-30 11:16:32 +01:00
Sebastian Dröge
96448e82a7 ci: Update to Rust 1.79
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:44:05 +03:00
Matthew Waters
64cc7d8baf ci: run tests with RUST_BACKTRACE=1
Produces backtraces which would allow some initial debugging on hard to
find issues.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:43:04 +03:00
Sebastian Dröge
ae16a8e276 Update CHANGELOG.md for 0.22.6
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:35:25 +03:00
Sebastian Dröge
cf3c8247ab Update versions to 0.22.6
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:31:29 +03:00
Sebastian Dröge
cf1be8f2bd Update Cargo.lock
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:31:04 +03:00
Sebastian Dröge
c5d800200a examples: Update to windows 0.57
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:29:46 +03:00
Sebastian Dröge
4ba6e88de9 Regenerate with latest gir
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:28:50 +03:00
Sebastian Dröge
93faf4ddaf Update gir
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:27:40 +03:00
Sebastian Dröge
529b91b524 Fix various new 1.79 clippy warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1467>
2024-06-19 18:26:57 +03:00
Tim-Philipp Müller
4c3146d5bd log: fix panic when using a log id with a formatted log message
Would panic because of a missing NUL terminator:

thread '<unnamed>' panicked at .. glib/src/gstring.rs:61:9:
assertion failed: !bytes.is_empty() && bytes[bytes.len() - 1] == 0

 3: glib::gstring::GStr::from_utf8_with_nul_unchecked
 4: gstreamer::log::DebugCategory::log_id_unfiltered_internal
      at gstreamer-rs/gstreamer/src/log.rs:465
 5: gstreamer::log::DebugCategory::log_id_unfiltered
      at gstreamer-rs/gstreamer/src/log.rs:425

Also enable logging on the category, so the logging code paths
are actually run here in the tests.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1453>
2024-06-02 17:42:58 +03:00
Sebastian Dröge
7160f53394 Update versions to 0.22.5 2024-05-23 15:50:09 +03:00
Sebastian Dröge
fc554b7486 Update CHANGELOG.md for 0.22.5 2024-05-23 15:49:51 +03:00
Sebastian Dröge
a6353e70c7 pbutils: encoding_profile: Remove unintentionally backported new API 2024-05-23 15:44:12 +03:00
Sebastian Dröge
5b0ee8a256 Update versions to 0.22.5 2024-05-23 15:39:14 +03:00
Sebastian Dröge
b1d7714a62 Update Cargo.lock
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:52:11 +03:00
Sebastian Dröge
77a012114d gstreamer: caps: Add missing assertion in Caps::remove_structure()
Part of 9e2c6268cb.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:50:33 +03:00
Tim-Philipp Müller
f055daf01b gstreamer: bufferlist: add another test for foreach_mut
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:54 +03:00
Sebastian Dröge
4ca6dc3853 gstreamer: bufferlist: Check index/length when removing a buffer
Out of range values give assertions in the C function.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:44 +03:00
Sebastian Dröge
61b69db8e1 gstreamer: bufferlist: Check for out of range indices before trying to get buffer
Passing an index bigger than the length will cause an assertion in the C
function.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:30 +03:00
Sebastian Dröge
72ba13410e Update to itertools 0.13
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:22 +03:00
Seungha Yang
93348efcbf event: Fix leak in SelectStreamsBuilder
gst_event_new_select_streams() does not take ownership of GList

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:17 +03:00
Mathieu Duponchelle
bc4908eead streamproducer: expose set_forward_preroll() API
This is useful to decide whether the preroll sample should be forwarded
to consumers when prerolling or only once it is time to render it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:45:09 +03:00
Sebastian Dröge
627ee652d7 ci: Update to rustup 1.27.1
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:44:33 +03:00
Naglis Jonaitis
f7a147bab4 examples: Update playbin flag handling snippet
Closes #512

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:44:06 +03:00
Sebastian Dröge
6b0d286c87 Fix various new 1.78 clippy warnings
Quite a bit of API was accidentally not exported but apparently nobody
was using it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:43:57 +03:00
Sebastian Dröge
e183ee5849 ci: Update to Rust 1.78.0
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:43:46 +03:00
Sebastian Dröge
e95262d558 rtp: Only use glib::translate if 1.24 APIs are enabled
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:42:58 +03:00
Sebastian Dröge
3c21817741 video: Remove some unnecessary #[cfg] attributes
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1447>
2024-05-23 09:42:42 +03:00
Jordan Petridis
a0a23c6f45 ci: Set DEFAULT_BRANCH for windows image to gstreamer stable
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1430>
2024-04-28 10:25:17 +03:00
Sebastian Dröge
cca58ce1ff audio: video: Improve Display trait impl test for AudioFormat and Video a bit
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1430>
2024-04-27 19:29:52 +03:00
Sebastian Dröge
4c36f8b5f9 video: Remove nonsensical test
Printing an unknown video format returns NULL, and with latest git main
this actually causes a critical warning in addition.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1430>
2024-04-27 19:29:51 +03:00
Jordan Petridis
14df7bd20f ci: Add libflac in the debian image
So we can build flac elements.

Related: https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1401
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1430>
2024-04-27 12:13:49 +03:00