mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-22 01:21:05 +00:00
gstreamer: Re-export / manually implement new standalone functions
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1385>
This commit is contained in:
parent
e16832a2a8
commit
a3b3017d75
1 changed files with 17 additions and 0 deletions
|
@ -13,6 +13,10 @@ pub use crate::auto::functions::{
|
|||
main_executable_path, util_get_timestamp as get_timestamp, version, version_string,
|
||||
};
|
||||
|
||||
#[cfg(feature = "v1_24")]
|
||||
#[cfg_attr(docsrs, doc(cfg(feature = "v1_24")))]
|
||||
pub use crate::auto::functions::util_ceil_log2 as ceil_log2;
|
||||
|
||||
#[doc(alias = "gst_calculate_linear_regression")]
|
||||
pub fn calculate_linear_regression(
|
||||
xy: &[(u64, u64)],
|
||||
|
@ -70,6 +74,19 @@ pub fn active_tracers() -> glib::List<Tracer> {
|
|||
unsafe { FromGlibPtrContainer::from_glib_full(ffi::gst_tracing_get_active_tracers()) }
|
||||
}
|
||||
|
||||
#[cfg(feature = "v1_24")]
|
||||
#[cfg_attr(docsrs, doc(cfg(feature = "v1_24")))]
|
||||
#[doc(alias = "gst_util_filename_compare")]
|
||||
pub fn filename_compare(a: &std::path::Path, b: &std::path::Path) -> std::cmp::Ordering {
|
||||
skip_assert_initialized!();
|
||||
unsafe {
|
||||
from_glib(ffi::gst_util_filename_compare(
|
||||
a.to_glib_none().0,
|
||||
b.to_glib_none().0,
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
|
Loading…
Reference in a new issue