diff --git a/gstreamer/src/error.rs b/gstreamer/src/error.rs index 276ba2a45..3d5e21703 100644 --- a/gstreamer/src/error.rs +++ b/gstreamer/src/error.rs @@ -118,13 +118,13 @@ macro_rules! gst_loggable_error( macro_rules! gst_result_from_gboolean( // Plain strings ($gst_sys_bool:expr, $cat:expr, $msg:expr) => { - glib_result_from_gboolean!($gst_sys_bool, $msg) + $crate::glib::glib_result_from_gboolean!($gst_sys_bool, $msg) .map_err(|bool_err| $crate::LoggableError::new($cat.clone(), bool_err)) }; // Format strings ($gst_sys_bool:expr, $cat:expr, $($msg:tt)*) => { { - glib_result_from_gboolean!($gst_sys_bool, $($msg)*) + $crate::glib::glib_result_from_gboolean!($gst_sys_bool, $($msg)*) .map_err(|bool_err| $crate::LoggableError::new($cat.clone(), bool_err)) }}; ); diff --git a/gstreamer/src/log.rs b/gstreamer/src/log.rs index 0bf09e421..ad18a5623 100644 --- a/gstreamer/src/log.rs +++ b/gstreamer/src/log.rs @@ -219,80 +219,80 @@ declare_debug_category_from_name!(CAT_CONTEXT, "GST_CONTEXT"); #[macro_export] macro_rules! gst_error( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Error, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Error, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Error, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Error, $($args)*) }}; ); #[macro_export] macro_rules! gst_warning( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Warning, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Warning, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Warning, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Warning, $($args)*) }}; ); #[macro_export] macro_rules! gst_fixme( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Fixme, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Fixme, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Fixme, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Fixme, $($args)*) }}; ); #[macro_export] macro_rules! gst_info( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Info, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Info, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Info, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Info, $($args)*) }}; ); #[macro_export] macro_rules! gst_debug( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Debug, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Debug, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Debug, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Debug, $($args)*) }}; ); #[macro_export] macro_rules! gst_log( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Log, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Log, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Log, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Log, $($args)*) }}; ); #[macro_export] macro_rules! gst_trace( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Trace, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Trace, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Trace, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Trace, $($args)*) }}; ); #[macro_export] macro_rules! gst_memdump( ($cat:expr, obj: $obj:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Memdump, obj: $obj, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Memdump, obj: $obj, $($args)*) }}; ($cat:expr, $($args:tt)*) => { { - gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Memdump, $($args)*) + $crate::gst_log_with_level!($cat.clone(), level: $crate::DebugLevel::Memdump, $($args)*) }}; ); diff --git a/gstreamer/src/subclass/plugin_1_12.rs b/gstreamer/src/subclass/plugin_1_12.rs index 89815e425..095a2a7b9 100644 --- a/gstreamer/src/subclass/plugin_1_12.rs +++ b/gstreamer/src/subclass/plugin_1_12.rs @@ -46,7 +46,7 @@ macro_rules! gst_plugin_define( pub fn plugin_register_static() -> Result<(), glib::BoolError> { unsafe { - glib_result_from_gboolean!( + $crate::glib::glib_result_from_gboolean!( $crate::gst_sys::gst_plugin_register_static( $crate::subclass::plugin::MAJOR_VERSION, $crate::subclass::plugin::MINOR_VERSION, @@ -73,18 +73,18 @@ macro_rules! gst_plugin_define( Ok(_) => $crate::glib_sys::GTRUE, Err(err) => { let cat = $crate::DebugCategory::get("GST_PLUGIN_LOADING").unwrap(); - gst_error!(cat, "Failed to register plugin: {}", err); + $crate::gst_error!(cat, "Failed to register plugin: {}", err); $crate::glib_sys::GFALSE } } Err(err) => { let cat = $crate::DebugCategory::get("GST_PLUGIN_LOADING").unwrap(); if let Some(cause) = err.downcast_ref::<&str>() { - gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); } else if let Some(cause) = err.downcast_ref::() { - gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); } else { - gst_error!(cat, "Failed to initialize plugin due to panic"); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic"); } $crate::glib_sys::GFALSE diff --git a/gstreamer/src/subclass/plugin_1_14.rs b/gstreamer/src/subclass/plugin_1_14.rs index 418f03369..dd5b7d803 100644 --- a/gstreamer/src/subclass/plugin_1_14.rs +++ b/gstreamer/src/subclass/plugin_1_14.rs @@ -42,7 +42,7 @@ macro_rules! gst_plugin_define( pub fn plugin_register_static() -> Result<(), glib::BoolError> { unsafe { - glib_result_from_gboolean!( + $crate::glib::glib_result_from_gboolean!( $crate::gst_sys::gst_plugin_register_static( $crate::subclass::plugin::MAJOR_VERSION, $crate::subclass::plugin::MINOR_VERSION, @@ -81,18 +81,18 @@ macro_rules! gst_plugin_define( Ok(_) => $crate::glib_sys::GTRUE, Err(err) => { let cat = $crate::DebugCategory::get("GST_PLUGIN_LOADING").unwrap(); - gst_error!(cat, "Failed to register plugin: {}", err); + $crate::gst_error!(cat, "Failed to register plugin: {}", err); $crate::glib_sys::GFALSE } } Err(err) => { let cat = $crate::DebugCategory::get("GST_PLUGIN_LOADING").unwrap(); if let Some(cause) = err.downcast_ref::<&str>() { - gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); } else if let Some(cause) = err.downcast_ref::() { - gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic: {}", cause); } else { - gst_error!(cat, "Failed to initialize plugin due to panic"); + $crate::gst_error!(cat, "Failed to initialize plugin due to panic"); } $crate::glib_sys::GFALSE