2019-08-13 17:12:09 +00:00
|
|
|
// 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
|
|
|
|
|
2020-11-22 10:32:36 +00:00
|
|
|
use bitflags::bitflags;
|
2019-08-13 17:12:09 +00:00
|
|
|
use glib::translate::*;
|
|
|
|
use glib::value::FromValue;
|
|
|
|
use glib::value::FromValueOptional;
|
|
|
|
use glib::value::SetValue;
|
|
|
|
use glib::StaticType;
|
|
|
|
use glib::Type;
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
bitflags! {
|
|
|
|
pub struct RTPBufferFlags: u32 {
|
|
|
|
const RETRANSMISSION = 1048576;
|
|
|
|
const REDUNDANT = 2097152;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
#[doc(hidden)]
|
|
|
|
impl ToGlib for RTPBufferFlags {
|
2020-11-22 10:32:36 +00:00
|
|
|
type GlibType = ffi::GstRTPBufferFlags;
|
2019-08-13 17:12:09 +00:00
|
|
|
|
2020-11-22 10:32:36 +00:00
|
|
|
fn to_glib(&self) -> ffi::GstRTPBufferFlags {
|
2019-08-13 17:12:09 +00:00
|
|
|
self.bits()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
#[doc(hidden)]
|
2020-11-22 10:32:36 +00:00
|
|
|
impl FromGlib<ffi::GstRTPBufferFlags> for RTPBufferFlags {
|
2020-12-08 13:00:17 +00:00
|
|
|
unsafe fn from_glib(value: ffi::GstRTPBufferFlags) -> RTPBufferFlags {
|
2019-08-13 17:12:09 +00:00
|
|
|
skip_assert_initialized!();
|
|
|
|
RTPBufferFlags::from_bits_truncate(value)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
impl StaticType for RTPBufferFlags {
|
|
|
|
fn static_type() -> Type {
|
2020-11-22 10:32:36 +00:00
|
|
|
unsafe { from_glib(ffi::gst_rtp_buffer_flags_get_type()) }
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
impl<'a> FromValueOptional<'a> for RTPBufferFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn from_value_optional(value: &glib::Value) -> Option<Self> {
|
2019-08-13 17:12:09 +00:00
|
|
|
Some(FromValue::from_value(value))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
impl<'a> FromValue<'a> for RTPBufferFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn from_value(value: &glib::Value) -> Self {
|
2020-11-22 10:32:36 +00:00
|
|
|
from_glib(glib::gobject_ffi::g_value_get_flags(value.to_glib_none().0))
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-11-27 13:37:24 +00:00
|
|
|
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
|
|
|
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
|
2019-08-13 17:12:09 +00:00
|
|
|
impl SetValue for RTPBufferFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn set_value(value: &mut glib::Value, this: &Self) {
|
2020-11-22 10:32:36 +00:00
|
|
|
glib::gobject_ffi::g_value_set_flags(value.to_glib_none_mut().0, this.to_glib())
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
bitflags! {
|
|
|
|
pub struct RTPBufferMapFlags: u32 {
|
|
|
|
const SKIP_PADDING = 65536;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[doc(hidden)]
|
|
|
|
impl ToGlib for RTPBufferMapFlags {
|
2020-11-22 10:32:36 +00:00
|
|
|
type GlibType = ffi::GstRTPBufferMapFlags;
|
2019-08-13 17:12:09 +00:00
|
|
|
|
2020-11-22 10:32:36 +00:00
|
|
|
fn to_glib(&self) -> ffi::GstRTPBufferMapFlags {
|
2019-08-13 17:12:09 +00:00
|
|
|
self.bits()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#[doc(hidden)]
|
2020-11-22 10:32:36 +00:00
|
|
|
impl FromGlib<ffi::GstRTPBufferMapFlags> for RTPBufferMapFlags {
|
2020-12-08 13:00:17 +00:00
|
|
|
unsafe fn from_glib(value: ffi::GstRTPBufferMapFlags) -> RTPBufferMapFlags {
|
2019-08-13 17:12:09 +00:00
|
|
|
skip_assert_initialized!();
|
|
|
|
RTPBufferMapFlags::from_bits_truncate(value)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl StaticType for RTPBufferMapFlags {
|
|
|
|
fn static_type() -> Type {
|
2020-11-22 10:32:36 +00:00
|
|
|
unsafe { from_glib(ffi::gst_rtp_buffer_map_flags_get_type()) }
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> FromValueOptional<'a> for RTPBufferMapFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn from_value_optional(value: &glib::Value) -> Option<Self> {
|
2019-08-13 17:12:09 +00:00
|
|
|
Some(FromValue::from_value(value))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> FromValue<'a> for RTPBufferMapFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn from_value(value: &glib::Value) -> Self {
|
2020-11-22 10:32:36 +00:00
|
|
|
from_glib(glib::gobject_ffi::g_value_get_flags(value.to_glib_none().0))
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl SetValue for RTPBufferMapFlags {
|
2020-11-27 13:37:24 +00:00
|
|
|
unsafe fn set_value(value: &mut glib::Value, this: &Self) {
|
2020-11-22 10:32:36 +00:00
|
|
|
glib::gobject_ffi::g_value_set_flags(value.to_glib_none_mut().0, this.to_glib())
|
2019-08-13 17:12:09 +00:00
|
|
|
}
|
|
|
|
}
|