For some reason (compiler bug?), the rust compiler fails to compare u32 and f64 types
when doing a wildcard cast on i586 with the following error:
error[E0282]: type annotations needed
--> audio/csound/src/filter/imp.rs:611:47
|
611 | if rate != out_info.rate() || rate != csound.get_sample_rate() as _ {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ cannot infer type
|
= note: type must be known at this point
Using an explicit cast solves the issue.
It's only accessed from the streaming thread and in PAUSED->READY after
the streaming thread was shut down, so it's already guaranteed that only
a single thread can access it at any time.
cargo-c will produce a pkg-config file making it easier to statically
link plugins.
Also add 'static' features for plugins depending on < 1.14 as this is the
minimal required version to use static linking because of ABI changes in
core.
There is no way to dynamically ask Cargo to build static or dynamic lib
so we have to build both and pick the one we care when doing the meson
processing.
Fix#88
The audiornnoise element can be used as playbin audio-filter for instance, to
suppress noise in the audio stream.
This plugin relies on the nnnoiseless crate which implements the noise removal
algorithm of the Xiph RNNoise library, in Rust. Some demos and documentation of
the RNNoise C library can be found on:
https://people.xiph.org/~jm/demo/rnnoise/Fixes#114
Only two uses of unsafely setting the pad functions is left:
- fallbacksrc for overriding the chain function of the proxy pad of a
ghost pad
- threadshare for overriding the pad functions after creationg, which
probably needs some fixing at some point
The current implementation only makes use of non-partial results,
requiring a crazy high latency.
With this mode, we use items from partial results when they're
older than latency - 2 * GRANULARITY_MS. Depending on the latency
that the user has set this may result in reduced accuracy, the
default latency has been modified to a pretty conservative sweet
spot of 8 seconds.
This complexifies the code a bit, as items aren't identified by
AWS, and their timings can change.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/348>