diff --git a/gstreamer/src/structure.rs b/gstreamer/src/structure.rs index e2063cee5..4914ebf24 100644 --- a/gstreamer/src/structure.rs +++ b/gstreamer/src/structure.rs @@ -281,6 +281,18 @@ impl FromGlibPtrFull<*mut ffi::GstStructure> for Structure { } } +impl FromGlibPtrBorrow<*const ffi::GstStructure> for Structure { + unsafe fn from_glib_borrow(ptr: *const ffi::GstStructure) -> Borrowed { + Borrowed::new(from_glib_full(ptr)) + } +} + +impl FromGlibPtrBorrow<*mut ffi::GstStructure> for Structure { + unsafe fn from_glib_borrow(ptr: *mut ffi::GstStructure) -> Borrowed { + Borrowed::new(from_glib_full(ptr)) + } +} + impl glib::value::ValueType for Structure { type Type = Self; }