2018-04-23 17:34:22 +00:00
|
|
|
// This file was generated by gir (https://github.com/gtk-rs/gir)
|
|
|
|
// from gir-files (https://github.com/gtk-rs/gir-files)
|
2021-04-01 13:58:41 +00:00
|
|
|
// from gst-gir-files (https://gitlab.freedesktop.org/gstreamer/gir-files-rs.git)
|
2017-07-04 22:47:33 +00:00
|
|
|
// DO NOT EDIT
|
|
|
|
|
2020-11-21 13:46:33 +00:00
|
|
|
use crate::Object;
|
|
|
|
use crate::Stream;
|
|
|
|
use glib::translate::*;
|
2017-07-04 22:47:33 +00:00
|
|
|
|
2020-12-17 22:34:53 +00:00
|
|
|
glib::wrapper! {
|
2020-11-21 13:46:33 +00:00
|
|
|
pub struct StreamCollection(Object<ffi::GstStreamCollection, ffi::GstStreamCollectionClass>) @extends Object;
|
2017-07-04 22:47:33 +00:00
|
|
|
|
|
|
|
match fn {
|
2021-04-19 19:55:01 +00:00
|
|
|
type_ => || ffi::gst_stream_collection_get_type(),
|
2017-07-04 22:47:33 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl StreamCollection {
|
2020-12-08 13:00:17 +00:00
|
|
|
#[doc(alias = "gst_stream_collection_get_size")]
|
2021-04-11 19:38:18 +00:00
|
|
|
pub fn size(&self) -> u32 {
|
2020-11-21 13:46:33 +00:00
|
|
|
unsafe { ffi::gst_stream_collection_get_size(self.to_glib_none().0) }
|
2017-07-04 22:47:33 +00:00
|
|
|
}
|
|
|
|
|
2020-12-08 13:00:17 +00:00
|
|
|
#[doc(alias = "gst_stream_collection_get_stream")]
|
2017-08-17 11:50:25 +00:00
|
|
|
pub fn get_stream(&self, index: u32) -> Option<Stream> {
|
2017-07-04 22:47:33 +00:00
|
|
|
unsafe {
|
2020-11-21 13:46:33 +00:00
|
|
|
from_glib_none(ffi::gst_stream_collection_get_stream(
|
2019-06-18 10:12:00 +00:00
|
|
|
self.to_glib_none().0,
|
|
|
|
index,
|
|
|
|
))
|
2017-07-04 22:47:33 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-12-08 13:00:17 +00:00
|
|
|
#[doc(alias = "gst_stream_collection_get_upstream_id")]
|
2021-04-11 19:38:18 +00:00
|
|
|
pub fn upstream_id(&self) -> Option<glib::GString> {
|
2017-07-04 22:47:33 +00:00
|
|
|
unsafe {
|
2020-11-21 13:46:33 +00:00
|
|
|
from_glib_none(ffi::gst_stream_collection_get_upstream_id(
|
2019-06-18 10:12:00 +00:00
|
|
|
self.to_glib_none().0,
|
|
|
|
))
|
2017-07-04 22:47:33 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-02-28 16:30:54 +00:00
|
|
|
//pub fn connect_stream_notify<Unsupported or ignored types>(&self, detail: Option<&str>, f: F) -> SignalHandlerId {
|
2017-07-04 22:47:33 +00:00
|
|
|
// Ignored p0: GObject.ParamSpec
|
|
|
|
//}
|
|
|
|
}
|
2017-08-17 11:50:25 +00:00
|
|
|
|
|
|
|
unsafe impl Send for StreamCollection {}
|
|
|
|
unsafe impl Sync for StreamCollection {}
|