mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-26 19:41:09 +00:00
gstreamer/element: Add support for ElementClass::add_metadata()
This commit is contained in:
parent
6dcd255815
commit
7868018abb
1 changed files with 10 additions and 0 deletions
|
@ -305,6 +305,16 @@ pub unsafe trait ElementClassSubclassExt: Sized + 'static {
|
|||
);
|
||||
}
|
||||
}
|
||||
|
||||
fn add_metadata(&mut self, key: &str, value: &str) {
|
||||
unsafe {
|
||||
gst_sys::gst_element_class_add_metadata(
|
||||
self as *mut Self as *mut gst_sys::GstElementClass,
|
||||
key.to_glib_none().0,
|
||||
value.to_glib_none().0,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
unsafe impl ElementClassSubclassExt for ElementClass {}
|
||||
|
|
Loading…
Reference in a new issue