gstreamer-rs/gstreamer-base/src/auto/aggregator_pad.rs
2019-04-15 18:38:05 +03:00

76 lines
2.3 KiB
Rust

// This file was generated by gir (https://github.com/gtk-rs/gir)
// from gir-files (https://github.com/gtk-rs/gir-files)
// DO NOT EDIT
use glib::object::IsA;
use glib::translate::*;
use gst;
use gst_base_sys;
glib_wrapper! {
pub struct AggregatorPad(Object<gst_base_sys::GstAggregatorPad, gst_base_sys::GstAggregatorPadClass, AggregatorPadClass>) @extends gst::Pad, gst::Object;
match fn {
get_type => || gst_base_sys::gst_aggregator_pad_get_type(),
}
}
unsafe impl Send for AggregatorPad {}
unsafe impl Sync for AggregatorPad {}
pub const NONE_AGGREGATOR_PAD: Option<&AggregatorPad> = None;
pub trait AggregatorPadExt: 'static {
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn drop_buffer(&self) -> bool;
#[cfg(any(feature = "v1_14_1", feature = "dox"))]
fn has_buffer(&self) -> bool;
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn is_eos(&self) -> bool;
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn peek_buffer(&self) -> Option<gst::Buffer>;
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn pop_buffer(&self) -> Option<gst::Buffer>;
}
impl<O: IsA<AggregatorPad>> AggregatorPadExt for O {
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn drop_buffer(&self) -> bool {
unsafe {
from_glib(gst_base_sys::gst_aggregator_pad_drop_buffer(self.as_ref().to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14_1", feature = "dox"))]
fn has_buffer(&self) -> bool {
unsafe {
from_glib(gst_base_sys::gst_aggregator_pad_has_buffer(self.as_ref().to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn is_eos(&self) -> bool {
unsafe {
from_glib(gst_base_sys::gst_aggregator_pad_is_eos(self.as_ref().to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn peek_buffer(&self) -> Option<gst::Buffer> {
unsafe {
from_glib_full(gst_base_sys::gst_aggregator_pad_peek_buffer(self.as_ref().to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn pop_buffer(&self) -> Option<gst::Buffer> {
unsafe {
from_glib_full(gst_base_sys::gst_aggregator_pad_pop_buffer(self.as_ref().to_glib_none().0))
}
}
}