1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
use ffi;
use glib::object::IsA;
use glib::translate::*;
use glib_ffi;
use gobject_ffi;
use gst;
use gst_ffi;
use std::mem;
use std::ptr;
glib_wrapper! {
pub struct AggregatorPad(Object<ffi::GstAggregatorPad, ffi::GstAggregatorPadClass>): [
gst::Pad => gst_ffi::GstPad,
gst::Object => gst_ffi::GstObject,
];
match fn {
get_type => || ffi::gst_aggregator_pad_get_type(),
}
}
unsafe impl Send for AggregatorPad {}
unsafe impl Sync for AggregatorPad {}
pub trait AggregatorPadExt {
#[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(ffi::gst_aggregator_pad_drop_buffer(self.to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14_1", feature = "dox"))]
fn has_buffer(&self) -> bool {
unsafe {
from_glib(ffi::gst_aggregator_pad_has_buffer(self.to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn is_eos(&self) -> bool {
unsafe {
from_glib(ffi::gst_aggregator_pad_is_eos(self.to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn peek_buffer(&self) -> Option<gst::Buffer> {
unsafe {
from_glib_full(ffi::gst_aggregator_pad_peek_buffer(self.to_glib_none().0))
}
}
#[cfg(any(feature = "v1_14", feature = "dox"))]
fn pop_buffer(&self) -> Option<gst::Buffer> {
unsafe {
from_glib_full(ffi::gst_aggregator_pad_pop_buffer(self.to_glib_none().0))
}
}
}