Revert "Remove unnecessary dox feature"

This reverts commit 9dd8bd9095.
This commit is contained in:
Guillaume Gomez 2020-11-27 14:37:49 +01:00
parent 2d87561193
commit 8f9d76bb8c
53 changed files with 577 additions and 577 deletions

View file

@ -229,8 +229,8 @@ impl AppSrc {
ret.into_result()
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn push_buffer_list(
&self,
list: gst::BufferList,

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -34,8 +34,8 @@ pub trait AudioDecoderExtManual: 'static {
frames: i32,
) -> Result<gst::FlowSuccess, gst::FlowError>;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn finish_subframe(
&self,
buffer: Option<gst::Buffer>,
@ -43,8 +43,8 @@ pub trait AudioDecoderExtManual: 'static {
fn negotiate(&self) -> Result<(), gst::FlowError>;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_output_caps(&self, caps: &gst::Caps) -> Result<(), gst::FlowError>;
fn set_output_format(&self, info: &AudioInfo) -> Result<(), gst::FlowError>;
@ -80,8 +80,8 @@ impl<O: IsA<AudioDecoder>> AudioDecoderExtManual for O {
ret.into_result()
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn finish_subframe(
&self,
buffer: Option<gst::Buffer>,
@ -108,8 +108,8 @@ impl<O: IsA<AudioDecoder>> AudioDecoderExtManual for O {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_output_caps(&self, caps: &gst::Caps) -> Result<(), gst::FlowError> {
unsafe {
let ret = from_glib(ffi::gst_audio_decoder_set_output_caps(

View file

@ -8,16 +8,16 @@
// except according to those terms.
use std::fmt;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use std::ptr;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use std::slice;
use glib::translate::{from_glib, ToGlib};
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use glib::translate::{from_glib_none, ToGlibPtr};
use gst::prelude::*;
@ -75,20 +75,20 @@ impl fmt::Debug for AudioClippingMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
#[repr(transparent)]
pub struct AudioMeta(ffi::GstAudioMeta);
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl Send for AudioMeta {}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl Sync for AudioMeta {}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl AudioMeta {
pub fn add<'a>(
buffer: &'a mut gst::BufferRef,
@ -196,8 +196,8 @@ impl AudioMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl MetaAPI for AudioMeta {
type GstType = ffi::GstAudioMeta;
@ -206,8 +206,8 @@ unsafe impl MetaAPI for AudioMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl fmt::Debug for AudioMeta {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("AudioMeta")

View file

@ -12,8 +12,8 @@ use glib::translate::*;
use std::mem;
impl AudioStreamAlign {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn process(
&mut self,
discont: bool,

View file

@ -30,8 +30,8 @@ pub fn audio_buffer_clip(
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn audio_buffer_truncate(
buffer: gst::Buffer,
bpf: u32,

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;
@ -41,16 +41,16 @@ mod audio_meta;
pub use crate::audio_meta::*;
mod audio_channel_position;
pub use crate::audio_channel_position::*;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
mod audio_stream_align;
mod functions;
pub use crate::functions::*;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub mod audio_buffer;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub use audio_buffer::{AudioBuffer, AudioBufferRef};
mod audio_decoder;

View file

@ -83,14 +83,14 @@ impl UniqueAdapter {
self.0.copy_bytes(offset, size)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn distance_from_discont(&self) -> u64 {
self.0.distance_from_discont()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn dts_at_discont(&self) -> gst::ClockTime {
self.0.dts_at_discont()
}
@ -129,8 +129,8 @@ impl UniqueAdapter {
self.0.masked_scan_uint32_peek(mask, pattern, offset, size)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn offset_at_discont(&self) -> u64 {
self.0.offset_at_discont()
}
@ -143,8 +143,8 @@ impl UniqueAdapter {
self.0.prev_dts_at_offset(offset)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn prev_offset(&self) -> (u64, u64) {
self.0.prev_offset()
}
@ -157,8 +157,8 @@ impl UniqueAdapter {
self.0.prev_pts_at_offset(offset)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn pts_at_discont(&self) -> gst::ClockTime {
self.0.pts_at_discont()
}

View file

@ -7,23 +7,23 @@
// except according to those terms.
use crate::Aggregator;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use glib::prelude::*;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use glib::signal::{connect_raw, SignalHandlerId};
use glib::translate::*;
use glib::IsA;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use glib::Value;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use std::boxed::Box as Box_;
use std::mem;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use std::mem::transmute;
use std::ptr;
@ -32,34 +32,34 @@ pub trait AggregatorExtManual: 'static {
fn finish_buffer(&self, buffer: gst::Buffer) -> Result<gst::FlowSuccess, gst::FlowError>;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn finish_buffer_list(
&self,
bufferlist: gst::BufferList,
) -> Result<gst::FlowSuccess, gst::FlowError>;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn get_property_min_upstream_latency(&self) -> gst::ClockTime;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_property_min_upstream_latency(&self, min_upstream_latency: gst::ClockTime);
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn connect_property_min_upstream_latency_notify<F: Fn(&Self) + Send + Sync + 'static>(
&self,
f: F,
) -> SignalHandlerId;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn update_segment<F: gst::FormattedValue>(&self, segment: &gst::FormattedSegment<F>);
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn selected_samples(
&self,
pts: gst::ClockTime,
@ -68,8 +68,8 @@ pub trait AggregatorExtManual: 'static {
info: Option<&gst::StructureRef>,
);
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn connect_samples_selected<
P,
F: Fn(
@ -113,8 +113,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
ret.into_result()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn finish_buffer_list(
&self,
bufferlist: gst::BufferList,
@ -128,8 +128,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
ret.into_result()
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn get_property_min_upstream_latency(&self) -> gst::ClockTime {
unsafe {
let mut value = Value::from_type(<gst::ClockTime as StaticType>::static_type());
@ -145,8 +145,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_property_min_upstream_latency(&self, min_upstream_latency: gst::ClockTime) {
unsafe {
glib::gobject_ffi::g_object_set_property(
@ -157,8 +157,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn connect_property_min_upstream_latency_notify<F: Fn(&Self) + Send + Sync + 'static>(
&self,
f: F,
@ -175,8 +175,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
)
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn update_segment<F: gst::FormattedValue>(&self, segment: &gst::FormattedSegment<F>) {
unsafe {
ffi::gst_aggregator_update_segment(
@ -186,8 +186,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn selected_samples(
&self,
pts: gst::ClockTime,
@ -208,8 +208,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn connect_samples_selected<
P,
F: Fn(
@ -279,8 +279,8 @@ impl<O: IsA<Aggregator>> AggregatorExtManual for O {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe extern "C" fn notify_min_upstream_latency_trampoline<P, F: Fn(&P) + Send + Sync + 'static>(
this: *mut ffi::GstAggregator,
_param_spec: glib::ffi::gpointer,

View file

@ -26,8 +26,8 @@ pub trait BaseSrcExtManual: 'static {
fn query_latency(&self) -> Result<(bool, gst::ClockTime, gst::ClockTime), glib::BoolError>;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn new_segment(&self, segment: &gst::Segment) -> Result<(), glib::BoolError>;
}
@ -101,8 +101,8 @@ impl<O: IsA<BaseSrc>> BaseSrcExtManual for O {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn new_segment(&self, segment: &gst::Segment) -> Result<(), glib::BoolError> {
unsafe {
let ret = from_glib(ffi::gst_base_src_new_segment(

View file

@ -33,8 +33,8 @@ pub fn type_find_helper_for_data<P: IsA<gst::Object>, R: AsRef<[u8]>>(
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn type_find_helper_for_data_with_extension<P: IsA<gst::Object>, R: AsRef<[u8]>>(
obj: Option<&P>,
data: R,
@ -80,8 +80,8 @@ pub fn type_find_helper_for_buffer<P: IsA<gst::Object>>(
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn type_find_helper_for_buffer_with_extension<P: IsA<gst::Object>>(
obj: Option<&P>,
buf: &gst::Buffer,

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;
@ -38,17 +38,17 @@ mod adapter;
pub use crate::adapter::*;
mod flow_combiner;
pub use crate::flow_combiner::*;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
mod aggregator;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use aggregator::AggregatorExtManual;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
mod aggregator_pad;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use aggregator_pad::AggregatorPadExtManual;
mod base_parse;
pub use crate::base_parse::BaseParseExtManual;
@ -72,11 +72,11 @@ pub mod prelude {
pub use glib::prelude::*;
pub use gst::prelude::*;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use crate::aggregator::AggregatorExtManual;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use crate::aggregator_pad::AggregatorPadExtManual;
pub use crate::auto::traits::*;
pub use crate::base_parse::BaseParseExtManual;

View file

@ -31,8 +31,8 @@ pub trait AggregatorImpl: AggregatorImplExt + ElementImpl {
self.parent_clip(aggregator, aggregator_pad, buffer)
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn finish_buffer_list(
&self,
aggregator: &Self::Type,
@ -58,8 +58,8 @@ pub trait AggregatorImpl: AggregatorImplExt + ElementImpl {
self.parent_sink_event(aggregator, aggregator_pad, event)
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn sink_event_pre_queue(
&self,
aggregator: &Self::Type,
@ -78,8 +78,8 @@ pub trait AggregatorImpl: AggregatorImplExt + ElementImpl {
self.parent_sink_query(aggregator, aggregator_pad, query)
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn sink_query_pre_queue(
&self,
aggregator: &Self::Type,
@ -156,14 +156,14 @@ pub trait AggregatorImpl: AggregatorImplExt + ElementImpl {
self.parent_negotiated_src_caps(aggregator, caps)
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn negotiate(&self, aggregator: &Self::Type) -> bool {
self.parent_negotiate(aggregator)
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn peek_next_sample(
&self,
aggregator: &Self::Type,
@ -189,8 +189,8 @@ pub trait AggregatorImplExt: ObjectSubclass {
buffer: gst::Buffer,
) -> Result<gst::FlowSuccess, gst::FlowError>;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_finish_buffer_list(
&self,
aggregator: &Self::Type,
@ -204,8 +204,8 @@ pub trait AggregatorImplExt: ObjectSubclass {
event: gst::Event,
) -> bool;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_sink_event_pre_queue(
&self,
aggregator: &Self::Type,
@ -220,8 +220,8 @@ pub trait AggregatorImplExt: ObjectSubclass {
query: &mut gst::QueryRef,
) -> bool;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_sink_query_pre_queue(
&self,
aggregator: &Self::Type,
@ -274,12 +274,12 @@ pub trait AggregatorImplExt: ObjectSubclass {
caps: &gst::Caps,
) -> Result<(), gst::LoggableError>;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_negotiate(&self, aggregator: &Self::Type) -> bool;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_peek_next_sample(
&self,
aggregator: &Self::Type,
@ -344,8 +344,8 @@ impl<T: AggregatorImpl> AggregatorImplExt for T {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_finish_buffer_list(
&self,
aggregator: &Self::Type,
@ -385,8 +385,8 @@ impl<T: AggregatorImpl> AggregatorImplExt for T {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_sink_event_pre_queue(
&self,
aggregator: &Self::Type,
@ -428,8 +428,8 @@ impl<T: AggregatorImpl> AggregatorImplExt for T {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_sink_query_pre_queue(
&self,
aggregator: &Self::Type,
@ -668,8 +668,8 @@ impl<T: AggregatorImpl> AggregatorImplExt for T {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_negotiate(&self, aggregator: &Self::Type) -> bool {
unsafe {
let data = T::type_data();
@ -686,8 +686,8 @@ impl<T: AggregatorImpl> AggregatorImplExt for T {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn parent_peek_next_sample(
&self,
aggregator: &Self::Type,
@ -732,7 +732,7 @@ where
klass.update_src_caps = Some(aggregator_update_src_caps::<T>);
klass.fixate_src_caps = Some(aggregator_fixate_src_caps::<T>);
klass.negotiated_src_caps = Some(aggregator_negotiated_src_caps::<T>);
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
{
klass.sink_event_pre_queue = Some(aggregator_sink_event_pre_queue::<T>);
klass.sink_query_pre_queue = Some(aggregator_sink_query_pre_queue::<T>);
@ -800,8 +800,8 @@ where
.to_glib()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe extern "C" fn aggregator_finish_buffer_list<T: AggregatorImpl>(
ptr: *mut ffi::GstAggregator,
buffer_list: *mut gst::ffi::GstBufferList,
@ -842,8 +842,8 @@ where
.to_glib()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe extern "C" fn aggregator_sink_event_pre_queue<T: AggregatorImpl>(
ptr: *mut ffi::GstAggregator,
aggregator_pad: *mut ffi::GstAggregatorPad,
@ -889,8 +889,8 @@ where
.to_glib()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe extern "C" fn aggregator_sink_query_pre_queue<T: AggregatorImpl>(
ptr: *mut ffi::GstAggregator,
aggregator_pad: *mut ffi::GstAggregatorPad,
@ -1143,8 +1143,8 @@ where
.to_glib()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe extern "C" fn aggregator_negotiate<T: AggregatorImpl>(
ptr: *mut ffi::GstAggregator,
) -> glib::ffi::gboolean
@ -1161,8 +1161,8 @@ where
.to_glib()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe extern "C" fn aggregator_peek_next_sample<T: AggregatorImpl>(
ptr: *mut ffi::GstAggregator,
pad: *mut ffi::GstAggregatorPad,

View file

@ -18,19 +18,19 @@ mod push_src;
pub use self::base_transform::BaseTransformMode;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
mod aggregator;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
mod aggregator_pad;
pub mod prelude {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use super::aggregator::{AggregatorImpl, AggregatorImplExt};
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use super::aggregator_pad::{AggregatorPadImpl, AggregatorPadImplExt};
pub use super::base_parse::{BaseParseImpl, BaseParseImplExt};
pub use super::base_sink::{BaseSinkImpl, BaseSinkImplExt};

View file

@ -90,8 +90,8 @@ impl Harness {
pad.add_probe(mask, func);
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn add_propose_allocation_meta(
&mut self,
api: glib::types::Type,
@ -462,8 +462,8 @@ impl Harness {
// unsafe { TODO: call ffi::gst_harness_stress_statechange_start_full() }
//}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn take_all_data_as_buffer(&mut self) -> Result<gst::Buffer, glib::BoolError> {
unsafe {
Option::<_>::from_glib_full(ffi::gst_harness_take_all_data_as_buffer(self.0.as_ptr()))
@ -471,8 +471,8 @@ impl Harness {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn take_all_data_as_bytes(&mut self) -> Result<glib::Bytes, glib::BoolError> {
unsafe {
Option::<_>::from_glib_full(ffi::gst_harness_take_all_data_as_bytes(self.0.as_ptr()))

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -35,8 +35,8 @@ impl TestClock {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn process_id(&self, pending_id: &gst::ClockId) -> bool {
unsafe {
from_glib(ffi::gst_test_clock_process_id(
@ -83,8 +83,8 @@ impl TestClock {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn timed_wait_for_multiple_pending_ids(
&self,
count: u32,

View file

@ -1,4 +1,4 @@
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -7,7 +7,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;
@ -37,14 +37,14 @@ mod gl_context;
pub use crate::gl_context::GLContextExtManual;
mod gl_display;
pub use crate::gl_display::GL_DISPLAY_CONTEXT_TYPE;
#[cfg(any(feature = "egl", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "egl")))]
#[cfg(any(feature = "egl", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "egl")))]
mod gl_display_egl;
#[cfg(any(feature = "wayland", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "wayland")))]
#[cfg(any(feature = "wayland", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "wayland")))]
mod gl_display_wayland;
#[cfg(any(feature = "x11", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "x11")))]
#[cfg(any(feature = "x11", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "x11")))]
mod gl_display_x11;
mod gl_video_frame;
pub use crate::gl_video_frame::VideoFrameGLExt;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -8,20 +8,20 @@
use crate::RTSPMediaFactory;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use glib::translate::*;
use glib::IsA;
pub trait RTSPMediaFactoryExtManual: 'static {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
fn add_role_from_structure(&self, structure: &gst::StructureRef);
}
impl<O: IsA<RTSPMediaFactory>> RTSPMediaFactoryExtManual for O {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
fn add_role_from_structure(&self, structure: &gst::StructureRef) {
unsafe {
ffi::gst_rtsp_media_factory_add_role_from_structure(

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;

View file

@ -11,15 +11,15 @@ use std::ffi::CStr;
use once_cell::sync::Lazy;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub static CAPS_FEATURE_FORMAT_INTERLACED: Lazy<&'static str> = Lazy::new(|| unsafe {
CStr::from_ptr(ffi::GST_CAPS_FEATURE_FORMAT_INTERLACED)
.to_str()
.unwrap()
});
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub static CAPS_FEATURES_FORMAT_INTERLACED: Lazy<CapsFeatures> =
Lazy::new(|| CapsFeatures::new(&[*CAPS_FEATURE_FORMAT_INTERLACED]));

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;
@ -30,8 +30,8 @@ mod auto;
pub use crate::auto::*;
mod caps_features;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub use crate::caps_features::{CAPS_FEATURES_FORMAT_INTERLACED, CAPS_FEATURE_FORMAT_INTERLACED};
pub use crate::caps_features::{
CAPS_FEATURES_META_GST_VIDEO_AFFINE_TRANSFORMATION_META,
@ -64,27 +64,27 @@ pub use crate::video_rectangle::*;
mod video_overlay_composition;
pub use crate::video_overlay_composition::*;
pub mod video_meta;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub use crate::video_meta::VideoCaptionMeta;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub use crate::video_meta::{VideoAFDMeta, VideoBarMeta};
pub use crate::video_meta::{
VideoAffineTransformationMeta, VideoCropMeta, VideoMeta, VideoOverlayCompositionMeta,
VideoRegionOfInterestMeta,
};
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
mod video_time_code;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub use crate::video_time_code::{ValidVideoTimeCode, VideoTimeCode, VideoTimeCodeMeta};
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
mod video_time_code_interval;
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
pub use crate::video_time_code_interval::VideoTimeCodeInterval;
mod video_buffer_pool;
pub use crate::video_buffer_pool::{

View file

@ -12,8 +12,8 @@ use crate::video_codec_state::{InNegotiation, Readable, VideoCodecState, VideoCo
use crate::VideoCodecFrame;
use crate::VideoDecoder;
use crate::VideoFormat;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use crate::VideoInterlaceMode;
use glib::object::IsA;
use glib::translate::*;
@ -35,8 +35,8 @@ extern "C" {
}
pub trait VideoDecoderExtManual: 'static {
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
fn allocate_output_frame(
&self,
frame: &mut VideoCodecFrame,
@ -65,8 +65,8 @@ pub trait VideoDecoderExtManual: 'static {
height: u32,
reference: Option<&VideoCodecState<Readable>>,
) -> Result<VideoCodecState<InNegotiation>, gst::FlowError>;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_interlaced_output_state(
&self,
fmt: VideoFormat,
@ -95,8 +95,8 @@ pub trait VideoDecoderExtManual: 'static {
}
impl<O: IsA<VideoDecoder>> VideoDecoderExtManual for O {
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
fn allocate_output_frame(
&self,
frame: &mut VideoCodecFrame,
@ -267,8 +267,8 @@ impl<O: IsA<VideoDecoder>> VideoDecoderExtManual for O {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
fn set_interlaced_output_state(
&self,
fmt: VideoFormat,

View file

@ -18,8 +18,8 @@ use std::mem;
use std::ptr;
pub trait VideoEncoderExtManual: 'static {
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
fn allocate_output_frame(
&self,
frame: &mut VideoCodecFrame,
@ -37,8 +37,8 @@ pub trait VideoEncoderExtManual: 'static {
frame: Option<VideoCodecFrame>,
) -> Result<gst::FlowSuccess, gst::FlowError>;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn finish_subframe(&self, frame: &VideoCodecFrame) -> Result<gst::FlowSuccess, gst::FlowError>;
fn get_latency(&self) -> (gst::ClockTime, gst::ClockTime);
@ -58,8 +58,8 @@ pub trait VideoEncoderExtManual: 'static {
}
impl<O: IsA<VideoEncoder>> VideoEncoderExtManual for O {
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
fn allocate_output_frame(
&self,
frame: &mut VideoCodecFrame,
@ -101,8 +101,8 @@ impl<O: IsA<VideoEncoder>> VideoEncoderExtManual for O {
ret.into_result()
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn finish_subframe(&self, frame: &VideoCodecFrame) -> Result<gst::FlowSuccess, gst::FlowError> {
let ret: gst::FlowReturn = unsafe {
from_glib(ffi::gst_video_encoder_finish_subframe(

View file

@ -203,8 +203,8 @@ impl fmt::Display for crate::VideoChromaSite {
}
impl crate::VideoTransferFunction {
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn from_iso(iso: u32) -> Result<crate::VideoTransferFunction, glib::BoolError> {
assert_initialized_main_thread!();
@ -219,14 +219,14 @@ impl crate::VideoTransferFunction {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn to_iso(&self) -> u32 {
unsafe { ffi::gst_video_transfer_function_to_iso(self.to_glib()) }
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn is_equivalent(
&self,
from_bpp: u32,
@ -245,8 +245,8 @@ impl crate::VideoTransferFunction {
}
impl crate::VideoColorMatrix {
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn from_iso(iso: u32) -> Result<crate::VideoColorMatrix, glib::BoolError> {
assert_initialized_main_thread!();
@ -261,16 +261,16 @@ impl crate::VideoColorMatrix {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn to_iso(&self) -> u32 {
unsafe { ffi::gst_video_color_matrix_to_iso(self.to_glib()) }
}
}
impl crate::VideoColorPrimaries {
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn from_iso(iso: u32) -> Result<crate::VideoColorPrimaries, glib::BoolError> {
assert_initialized_main_thread!();
@ -285,8 +285,8 @@ impl crate::VideoColorPrimaries {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn to_iso(&self) -> u32 {
unsafe { ffi::gst_video_color_primaries_to_iso(self.to_glib()) }
}
@ -340,7 +340,7 @@ impl fmt::Debug for VideoInfo {
.field("multiview_mode", &self.multiview_mode())
.field("multiview_flags", &self.multiview_flags());
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
b.field("field_order", &self.field_order());
b.finish()
@ -364,8 +364,8 @@ pub struct VideoInfoBuilder<'a> {
stride: Option<&'a [i32]>,
multiview_mode: Option<crate::VideoMultiviewMode>,
multiview_flags: Option<crate::VideoMultiviewFlags>,
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
field_order: Option<crate::VideoFieldOrder>,
}
@ -514,7 +514,7 @@ impl<'a> VideoInfoBuilder<'a> {
ptr::write(ptr.offset(1), multiview_flags.to_glib());
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
if let Some(field_order) = self.field_order {
let ptr = &mut info.ABI._gst_reserved as *mut _ as *mut i32;
ptr::write(ptr.offset(2), field_order.to_glib());
@ -608,8 +608,8 @@ impl<'a> VideoInfoBuilder<'a> {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
pub fn field_order(self, field_order: crate::VideoFieldOrder) -> Self {
Self {
field_order: Some(field_order),
@ -627,7 +627,7 @@ impl VideoInfo {
assert_initialized_main_thread!();
cfg_if::cfg_if! {
if #[cfg(any(feature = "v1_12", all(not(doctest), doc)))] {
if #[cfg(any(feature = "v1_12", feature = "dox"))] {
VideoInfoBuilder {
format,
width,
@ -722,8 +722,8 @@ impl VideoInfo {
self.0.height as u32
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn field_height(&self) -> u32 {
if self.0.interlace_mode == ffi::GST_VIDEO_INTERLACE_MODE_ALTERNATE {
(self.0.height as u32 + 1) / 2
@ -786,8 +786,8 @@ impl VideoInfo {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
pub fn field_order(&self) -> crate::VideoFieldOrder {
unsafe {
let ptr = &self.0.ABI._gst_reserved as *const _ as *const i32;
@ -999,8 +999,8 @@ impl glib::translate::FromGlibPtrFull<*mut ffi::GstVideoInfo> for VideoInfo {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
impl crate::VideoFieldOrder {
pub fn to_str<'a>(self) -> &'a str {
unsafe {
@ -1011,8 +1011,8 @@ impl crate::VideoFieldOrder {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
impl str::FromStr for crate::VideoFieldOrder {
type Err = glib::error::BoolError;
@ -1027,8 +1027,8 @@ impl str::FromStr for crate::VideoFieldOrder {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
impl fmt::Display for crate::VideoFieldOrder {
fn fmt(&self, f: &mut fmt::Formatter) -> Result<(), fmt::Error> {
f.write_str((*self).to_str())
@ -1144,8 +1144,8 @@ mod tests {
assert!(info == info2);
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
#[test]
fn test_video_align() {
gst::init().unwrap();
@ -1164,8 +1164,8 @@ mod tests {
assert_eq!(info.offset(), [0, 2_082_240]);
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
#[test]
fn test_display() {
use std::str::FromStr;

View file

@ -484,20 +484,20 @@ impl fmt::Debug for VideoOverlayCompositionMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
#[repr(transparent)]
pub struct VideoCaptionMeta(ffi::GstVideoCaptionMeta);
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl Send for VideoCaptionMeta {}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl Sync for VideoCaptionMeta {}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl VideoCaptionMeta {
pub fn add<'a>(
buffer: &'a mut gst::BufferRef,
@ -531,8 +531,8 @@ impl VideoCaptionMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
unsafe impl MetaAPI for VideoCaptionMeta {
type GstType = ffi::GstVideoCaptionMeta;
@ -541,8 +541,8 @@ unsafe impl MetaAPI for VideoCaptionMeta {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl fmt::Debug for VideoCaptionMeta {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("VideoCaptionMeta")
@ -552,20 +552,20 @@ impl fmt::Debug for VideoCaptionMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
#[repr(transparent)]
pub struct VideoAFDMeta(ffi::GstVideoAFDMeta);
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl Send for VideoAFDMeta {}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl Sync for VideoAFDMeta {}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
impl VideoAFDMeta {
pub fn add(
buffer: &mut gst::BufferRef,
@ -600,8 +600,8 @@ impl VideoAFDMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl MetaAPI for VideoAFDMeta {
type GstType = ffi::GstVideoAFDMeta;
@ -610,8 +610,8 @@ unsafe impl MetaAPI for VideoAFDMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
impl fmt::Debug for VideoAFDMeta {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("VideoAFDMeta")
@ -622,20 +622,20 @@ impl fmt::Debug for VideoAFDMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
#[repr(transparent)]
pub struct VideoBarMeta(ffi::GstVideoBarMeta);
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl Send for VideoBarMeta {}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl Sync for VideoBarMeta {}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
impl VideoBarMeta {
pub fn add(
buffer: &mut gst::BufferRef,
@ -676,8 +676,8 @@ impl VideoBarMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
unsafe impl MetaAPI for VideoBarMeta {
type GstType = ffi::GstVideoBarMeta;
@ -686,8 +686,8 @@ unsafe impl MetaAPI for VideoBarMeta {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
impl fmt::Debug for VideoBarMeta {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("VideoBarMeta")

View file

@ -15,13 +15,13 @@ use std::convert::{TryFrom, TryInto};
use std::fmt;
use std::mem;
use std::ptr;
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
use std::str;
use crate::VideoTimeCodeFlags;
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
use crate::VideoTimeCodeInterval;
pub struct VideoTimeCode(ffi::GstVideoTimeCode);
@ -68,8 +68,8 @@ impl VideoTimeCode {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn from_date_time(
fps: gst::Fraction,
dt: &glib::DateTime,
@ -178,8 +178,8 @@ impl ValidVideoTimeCode {
}
}
// #[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
// #[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
// pub fn from_date_time(
// fps: gst::Fraction,
// dt: &glib::DateTime,
@ -197,8 +197,8 @@ impl ValidVideoTimeCode {
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
pub fn add_interval(
&self,
tc_inter: &VideoTimeCodeInterval,
@ -470,8 +470,8 @@ macro_rules! generic_impl {
generic_impl!(VideoTimeCode);
generic_impl!(ValidVideoTimeCode);
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
impl str::FromStr for VideoTimeCode {
type Err = glib::error::BoolError;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
pub use ffi;
@ -28,8 +28,8 @@ macro_rules! skip_assert_initialized {
mod auto;
pub use crate::auto::*;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
mod web_rtc_data_channel;
mod web_rtc_session_description;

View file

@ -31,8 +31,8 @@ pub trait GstBinExtManual: 'static {
f: F,
) -> SignalHandlerId;
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn iterate_all_by_element_factory_name(&self, factory_name: &str) -> crate::Iterator<Element>;
fn iterate_all_by_interface(&self, iface: glib::types::Type) -> crate::Iterator<Element>;
fn iterate_elements(&self) -> crate::Iterator<Element>;
@ -108,8 +108,8 @@ impl<O: IsA<Bin>> GstBinExtManual for O {
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
fn iterate_all_by_element_factory_name(&self, factory_name: &str) -> crate::Iterator<Element> {
unsafe {
from_glib_full(ffi::gst_bin_iterate_all_by_element_factory_name(

View file

@ -1283,8 +1283,8 @@ mod tests {
assert_eq!(last, 4);
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
#[test]
fn test_meta_foreach() {
crate::init().unwrap();
@ -1318,8 +1318,8 @@ mod tests {
assert_eq!(&[crate::ClockTime::from(0), crate::SECOND][..], &res[..]);
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
#[test]
fn test_meta_foreach_mut() {
crate::init().unwrap();

View file

@ -66,8 +66,8 @@ impl BufferListRef {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn get_writable(&mut self, idx: u32) -> Option<&mut BufferRef> {
unsafe {
let ptr = ffi::gst_buffer_list_get_writable(self.as_mut_ptr(), idx);
@ -83,8 +83,8 @@ impl BufferListRef {
unsafe { ffi::gst_buffer_list_length(self.as_mut_ptr()) as usize }
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn calculate_size(&self) -> usize {
unsafe { ffi::gst_buffer_list_calculate_size(self.as_mut_ptr()) as usize }
}

View file

@ -13,7 +13,7 @@ cfg_if::cfg_if! {
use std::mem;
use std::os::unix;
} else if #[cfg(all(not(doctest), doc))] {
} else if #[cfg(feature = "dox")] {
// Declare a fake RawFd for doc generation on windows
pub mod unix {
pub mod io {
@ -39,7 +39,7 @@ impl UnixBusExtManual for Bus {
pollfd.fd
}
#[cfg(all(not(unix), all(not(doctest), doc)))]
#[cfg(all(not(unix), feature = "dox"))]
unix::io::RawFd {}
}
}

View file

@ -13,7 +13,7 @@ cfg_if::cfg_if! {
use std::mem;
use std::os::windows;
} else if #[cfg(all(not(doctest), doc))] {
} else if #[cfg(feature = "dox")] {
// Declare a fake RawHandle for doc generation on unix
pub mod windows {
pub mod io {
@ -39,7 +39,7 @@ impl WindowsBusExtManual for Bus {
pollfd.fd as *mut _
}
#[cfg(all(not(windows), all(not(doctest), doc)))]
#[cfg(all(not(windows), feature = "dox"))]
windows::io::RawHandle {}
}
}

View file

@ -249,8 +249,8 @@ impl CapsRef {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_features_simple(&mut self, features: Option<CapsFeatures>) {
unsafe {
ffi::gst_caps_set_features_simple(

View file

@ -15,8 +15,8 @@ use crate::ClockSuccess;
use crate::ClockTime;
use crate::ClockTimeDiff;
use glib::ffi::{gboolean, gpointer};
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
use glib::prelude::*;
use glib::translate::*;
use glib::IsA;
@ -66,14 +66,14 @@ impl ClockId {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_clock(&self) -> Option<Clock> {
unsafe { from_glib_full(ffi::gst_clock_id_get_clock(self.to_glib_none().0)) }
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn uses_clock<P: IsA<Clock>>(&self, clock: &P) -> bool {
unsafe {
from_glib(ffi::gst_clock_id_uses_clock(

View file

@ -27,28 +27,28 @@ use crate::StateChange;
use crate::StateChangeError;
use crate::StateChangeReturn;
use crate::StateChangeSuccess;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use glib::object::Cast;
use glib::object::IsA;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use glib::translate::FromGlibPtrBorrow;
use glib::translate::{
from_glib, from_glib_full, from_glib_none, FromGlib, FromGlibPtrContainer, ToGlib, ToGlibPtr,
};
use std::ffi::CStr;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use std::future::Future;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use std::marker::Unpin;
use std::mem;
use std::num::NonZeroU64;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use std::pin::Pin;
impl Element {
@ -171,8 +171,8 @@ pub trait ElementExtManual: 'static {
fn get_element_flags(&self) -> ElementFlags;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::too_many_arguments)]
fn message_full_with_details<T: crate::MessageErrorDomain>(
&self,
@ -201,24 +201,24 @@ pub trait ElementExtManual: 'static {
fn num_sink_pads(&self) -> u16;
fn num_src_pads(&self) -> u16;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn add_property_deep_notify_watch(
&self,
property_name: Option<&str>,
include_value: bool,
) -> NotifyWatchId;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn add_property_notify_watch(
&self,
property_name: Option<&str>,
include_value: bool,
) -> NotifyWatchId;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn remove_property_notify_watch(&self, watch_id: NotifyWatchId);
fn query_convert<V: Into<GenericFormattedValue>, U: SpecificFormattedValue>(
@ -252,14 +252,14 @@ pub trait ElementExtManual: 'static {
seek_pos: V,
) -> Result<(), glib::error::BoolError>;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn call_async<F>(&self, func: F)
where
F: FnOnce(&Self) + Send + 'static;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn call_async_future<F, T>(
&self,
func: F,
@ -423,8 +423,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn message_full_with_details<T: crate::MessageErrorDomain>(
&self,
type_: ElementMessageType,
@ -565,8 +565,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn add_property_deep_notify_watch(
&self,
property_name: Option<&str>,
@ -582,8 +582,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn add_property_notify_watch(
&self,
property_name: Option<&str>,
@ -599,8 +599,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn remove_property_notify_watch(&self, watch_id: NotifyWatchId) {
unsafe {
ffi::gst_element_remove_property_notify_watch(
@ -772,8 +772,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn call_async<F>(&self, func: F)
where
F: FnOnce(&Self) + Send + 'static,
@ -806,8 +806,8 @@ impl<O: IsA<Element>> ElementExtManual for O {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
fn call_async_future<F, T>(
&self,
func: F,

View file

@ -20,8 +20,8 @@ use std::ptr;
use glib::translate::{from_glib, from_glib_full, from_glib_none, ToGlib, ToGlibPtr};
use glib::value::ToSendValue;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
use glib::translate::FromGlibPtrContainer;
use crate::EventType;
@ -394,8 +394,8 @@ impl<'a> StreamStart<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_stream(&self) -> Option<crate::Stream> {
unsafe {
let mut stream = ptr::null_mut();
@ -459,23 +459,23 @@ impl<'a> Segment<'a> {
declare_concrete_event!(StreamCollection);
impl<'a> StreamCollection<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(stream_collection: &crate::StreamCollection) -> Event {
skip_assert_initialized!();
Self::builder(stream_collection).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(stream_collection: &crate::StreamCollection) -> StreamCollectionBuilder {
assert_initialized_main_thread!();
StreamCollectionBuilder::new(stream_collection)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_stream_collection(&self) -> crate::StreamCollection {
unsafe {
let mut stream_collection = ptr::null_mut();
@ -582,23 +582,23 @@ impl<'a> SinkMessage<'a> {
declare_concrete_event!(StreamGroupDone);
impl<'a> StreamGroupDone<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(group_id: GroupId) -> Event {
skip_assert_initialized!();
Self::builder(group_id).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(group_id: GroupId) -> StreamGroupDoneBuilder<'a> {
assert_initialized_main_thread!();
StreamGroupDoneBuilder::new(group_id)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_group_id(&self) -> GroupId {
unsafe {
let mut group_id = mem::MaybeUninit::uninit();
@ -890,8 +890,8 @@ impl<'a> Seek<'a> {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_trickmode_interval(&self) -> crate::ClockTime {
unsafe {
let mut trickmode_interval = mem::MaybeUninit::uninit();
@ -1037,23 +1037,23 @@ impl<'a> TocSelect<'a> {
declare_concrete_event!(SelectStreams);
impl<'a> SelectStreams<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(streams: &'a [&'a str]) -> Event {
skip_assert_initialized!();
Self::builder(streams).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(streams: &'a [&'a str]) -> SelectStreamsBuilder {
assert_initialized_main_thread!();
SelectStreamsBuilder::new(streams)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_streams(&self) -> Vec<String> {
unsafe {
let mut streams = ptr::null_mut();
@ -1281,8 +1281,8 @@ pub struct StreamStartBuilder<'a> {
stream_id: &'a str,
flags: Option<crate::StreamFlags>,
group_id: Option<GroupId>,
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
stream: Option<crate::Stream>,
}
@ -1294,8 +1294,8 @@ impl<'a> StreamStartBuilder<'a> {
stream_id,
flags: None,
group_id: None,
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
stream: None,
}
}
@ -1314,8 +1314,8 @@ impl<'a> StreamStartBuilder<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn stream(self, stream: crate::Stream) -> Self {
Self {
stream: Some(stream),
@ -1332,7 +1332,7 @@ impl<'a> StreamStartBuilder<'a> {
ffi::gst_event_set_group_id(ev, group_id.0.get());
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
if let Some(ref stream) = s.stream {
ffi::gst_event_set_stream(ev, stream.to_glib_none().0);
}
@ -1375,15 +1375,15 @@ impl<'a> SegmentBuilder<'a> {
event_builder_generic_impl!(|s: &Self| ffi::gst_event_new_segment(s.segment.to_glib_none().0));
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct StreamCollectionBuilder<'a> {
builder: EventBuilder<'a>,
stream_collection: &'a crate::StreamCollection,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> StreamCollectionBuilder<'a> {
fn new(stream_collection: &'a crate::StreamCollection) -> Self {
skip_assert_initialized!();
@ -1466,15 +1466,15 @@ impl<'a> SinkMessageBuilder<'a> {
));
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct StreamGroupDoneBuilder<'a> {
builder: EventBuilder<'a>,
group_id: GroupId,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> StreamGroupDoneBuilder<'a> {
fn new(group_id: GroupId) -> Self {
skip_assert_initialized!();
@ -1675,7 +1675,7 @@ impl<'a> SeekBuilder<'a> {
s.stop.get_value(),
);
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
if let Some(trickmode_interval) = s.trickmode_interval {
ffi::gst_event_set_seek_trickmode_interval(ev, trickmode_interval.to_glib());
}
@ -1783,15 +1783,15 @@ impl<'a> TocSelectBuilder<'a> {
event_builder_generic_impl!(|s: &Self| ffi::gst_event_new_toc_select(s.uid.to_glib_none().0));
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct SelectStreamsBuilder<'a> {
builder: EventBuilder<'a>,
streams: &'a [&'a str],
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> SelectStreamsBuilder<'a> {
fn new(streams: &'a [&'a str]) -> Self {
skip_assert_initialized!();

View file

@ -120,8 +120,8 @@ pub fn parse_launchv_full(
}
}
#[cfg(any(feature = "v1_12", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_12")))]
#[cfg(any(feature = "v1_12", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))]
pub fn calculate_linear_regression(
xy: &[(u64, u64)],
temp: Option<&mut [(u64, u64)]>,
@ -170,8 +170,8 @@ pub fn calculate_linear_regression(
}
}
#[cfg(any(feature = "v1_18", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_18")))]
#[cfg(any(feature = "v1_18", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
pub fn type_is_plugin_api(type_: glib::types::Type) -> Option<crate::PluginAPIFlags> {
assert_initialized_main_thread!();
unsafe {

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))]
#![cfg_attr(feature = "dox", feature(doc_cfg))]
#![recursion_limit = "256"]
// Re-exported for the subclass gst_plugin_define! macro
@ -83,11 +83,11 @@ pub use crate::tags::{
mod tags_serde;
pub mod meta;
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub use crate::meta::MetaSeqnum;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use crate::meta::ReferenceTimestampMeta;
pub use crate::meta::{Meta, MetaAPI, MetaRef, MetaRefMut, ParentBufferMeta, ProtectionMeta};
pub mod buffer;
@ -122,11 +122,11 @@ pub use crate::static_caps::*;
mod static_pad_template;
pub use crate::static_pad_template::*;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub mod promise;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub use promise::{Promise, PromiseError};
pub mod bus;
@ -143,16 +143,16 @@ mod allocation_params;
pub use self::allocation_params::AllocationParams;
// OS dependent Bus extensions (also import the other plateform mod for doc)
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
cfg_if::cfg_if! {
if #[cfg(unix)] {
mod bus_unix;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
mod bus_windows;
} else {
mod bus_windows;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
mod bus_unix;
}
}
@ -190,16 +190,16 @@ pub use crate::element::{
pub use crate::object::GstObjectExtManual;
// OS dependent Bus extensions (also import the other plateform trait for doc)
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
cfg_if::cfg_if! {
if #[cfg(unix)] {
pub use bus_unix::UnixBusExtManual;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
pub use bus_windows::WindowsBusExtManual;
} else {
pub use bus_windows::WindowsBusExtManual;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
pub use bus_unix::UnixBusExtManual;
}
}
@ -222,11 +222,11 @@ pub use crate::tag_setter::TagSetterExtManual;
mod plugin;
pub use crate::plugin::GstPluginExtManual;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub mod stream;
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub mod stream_collection;
mod typefind;
@ -320,16 +320,16 @@ pub mod prelude {
pub use crate::element::{ElementClassExt, ElementExtManual};
// OS dependent Bus extensions (also import the other plateform trait for doc)
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
cfg_if::cfg_if! {
if #[cfg(unix)] {
pub use crate::bus_unix::UnixBusExtManual;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
pub use crate::bus_windows::WindowsBusExtManual;
} else {
pub use crate::bus_windows::WindowsBusExtManual;
#[cfg(all(not(doctest), doc))]
#[cfg(feature = "dox")]
pub use crate::bus_unix::UnixBusExtManual;
}
}

View file

@ -267,8 +267,8 @@ impl<'a> Error<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_details(&self) -> Option<&StructureRef> {
unsafe {
let mut details = ptr::null();
@ -317,8 +317,8 @@ impl<'a> Warning<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_details(&self) -> Option<&StructureRef> {
unsafe {
let mut details = ptr::null();
@ -367,8 +367,8 @@ impl<'a> Info<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_details(&self) -> Option<&StructureRef> {
unsafe {
let mut details = ptr::null();
@ -1338,23 +1338,23 @@ impl<'a> DeviceRemoved<'a> {
declare_concrete_message!(PropertyNotify);
impl<'a> PropertyNotify<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(property_name: &str) -> Message {
skip_assert_initialized!();
Self::builder(property_name).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(property_name: &str) -> PropertyNotifyBuilder {
assert_initialized_main_thread!();
PropertyNotifyBuilder::new(property_name)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get(&self) -> (Object, &str, Option<&'a glib::Value>) {
unsafe {
let mut object = ptr::null_mut();
@ -1383,23 +1383,23 @@ impl<'a> PropertyNotify<'a> {
declare_concrete_message!(StreamCollection);
impl<'a> StreamCollection<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(collection: &crate::StreamCollection) -> Message {
skip_assert_initialized!();
Self::builder(collection).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(collection: &crate::StreamCollection) -> StreamCollectionBuilder {
assert_initialized_main_thread!();
StreamCollectionBuilder::new(collection)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_stream_collection(&self) -> crate::StreamCollection {
unsafe {
let mut collection = ptr::null_mut();
@ -1413,23 +1413,23 @@ impl<'a> StreamCollection<'a> {
declare_concrete_message!(StreamsSelected);
impl<'a> StreamsSelected<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(collection: &crate::StreamCollection) -> Message {
skip_assert_initialized!();
Self::builder(collection).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(collection: &crate::StreamCollection) -> StreamsSelectedBuilder {
assert_initialized_main_thread!();
StreamsSelectedBuilder::new(collection)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_stream_collection(&self) -> crate::StreamCollection {
unsafe {
let mut collection = ptr::null_mut();
@ -1440,8 +1440,8 @@ impl<'a> StreamsSelected<'a> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_streams(&self) -> Vec<crate::Stream> {
unsafe {
let n = ffi::gst_message_streams_selected_get_size(self.as_mut_ptr());
@ -1460,23 +1460,23 @@ impl<'a> StreamsSelected<'a> {
declare_concrete_message!(Redirect);
impl<'a> Redirect<'a> {
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(location: &str) -> Message {
skip_assert_initialized!();
Self::builder(location).build()
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn builder(location: &str) -> RedirectBuilder {
assert_initialized_main_thread!();
RedirectBuilder::new(location)
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn get_entries(&self) -> Vec<(&str, Option<TagList>, Option<&StructureRef>)> {
unsafe {
let n = ffi::gst_message_get_num_redirect_entries(self.as_mut_ptr());
@ -1514,16 +1514,16 @@ impl<'a> Redirect<'a> {
declare_concrete_message!(DeviceChanged);
impl<'a> DeviceChanged<'a> {
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
#[allow(clippy::new_ret_no_self)]
pub fn new(device: &'a crate::Device, changed_device: &'a crate::Device) -> Message {
skip_assert_initialized!();
Self::builder(device, changed_device).build()
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn builder(
device: &'a crate::Device,
changed_device: &'a crate::Device,
@ -1532,8 +1532,8 @@ impl<'a> DeviceChanged<'a> {
DeviceChangedBuilder::new(device, changed_device)
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_device_changed(&self) -> (crate::Device, crate::Device) {
unsafe {
let mut device = ptr::null_mut();
@ -1580,8 +1580,8 @@ impl<'a> MessageBuilder<'a> {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
fn other_fields(self, other_fields: &[(&'a str, &'a dyn ToSendValue)]) -> Self {
Self {
other_fields: self
@ -1613,8 +1613,8 @@ macro_rules! message_builder_generic_impl {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
#[allow(clippy::needless_update)]
pub fn other_fields(self, other_fields: &[(&'a str, &'a dyn ToSendValue)]) -> Self {
Self {
@ -1632,7 +1632,7 @@ macro_rules! message_builder_generic_impl {
ffi::gst_message_set_seqnum(msg, seqnum.0.get());
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
if !self.builder.other_fields.is_empty() {
let structure = ffi::gst_message_writable_structure(msg);
@ -1701,8 +1701,8 @@ impl<'a, T: MessageErrorDomain> ErrorBuilder<'a, T> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn details(self, details: Structure) -> Self {
Self {
details: Some(details),
@ -1712,7 +1712,7 @@ impl<'a, T: MessageErrorDomain> ErrorBuilder<'a, T> {
message_builder_generic_impl!(|s: &mut Self, src| {
cfg_if::cfg_if! {
if #[cfg(any(feature = "v1_10", all(not(doctest), doc)))] {
if #[cfg(any(feature = "v1_10", feature = "dox"))] {
let details = match s.details.take() {
None => ptr::null_mut(),
Some(details) => details.into_ptr(),
@ -1767,8 +1767,8 @@ impl<'a, T: MessageErrorDomain> WarningBuilder<'a, T> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn details(self, details: Structure) -> Self {
Self {
details: Some(details),
@ -1778,7 +1778,7 @@ impl<'a, T: MessageErrorDomain> WarningBuilder<'a, T> {
message_builder_generic_impl!(|s: &mut Self, src| {
cfg_if::cfg_if! {
if #[cfg(any(feature = "v1_10", all(not(doctest), doc)))] {
if #[cfg(any(feature = "v1_10", feature = "dox"))] {
let details = match s.details.take() {
None => ptr::null_mut(),
Some(details) => details.into_ptr(),
@ -1833,8 +1833,8 @@ impl<'a, T: MessageErrorDomain> InfoBuilder<'a, T> {
}
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub fn details(self, details: Structure) -> Self {
Self {
details: Some(details),
@ -1844,7 +1844,7 @@ impl<'a, T: MessageErrorDomain> InfoBuilder<'a, T> {
message_builder_generic_impl!(|s: &mut Self, src| {
cfg_if::cfg_if! {
if #[cfg(any(feature = "v1_10", all(not(doctest), doc)))] {
if #[cfg(any(feature = "v1_10", feature = "dox"))] {
let details = match s.details.take() {
None => ptr::null_mut(),
Some(details) => details.into_ptr(),
@ -2608,16 +2608,16 @@ impl<'a> DeviceRemovedBuilder<'a> {
));
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct PropertyNotifyBuilder<'a> {
builder: MessageBuilder<'a>,
property_name: &'a str,
value: Option<&'a dyn glib::ToSendValue>,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> PropertyNotifyBuilder<'a> {
fn new(property_name: &'a str) -> Self {
skip_assert_initialized!();
@ -2649,15 +2649,15 @@ impl<'a> PropertyNotifyBuilder<'a> {
});
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct StreamCollectionBuilder<'a> {
builder: MessageBuilder<'a>,
collection: &'a crate::StreamCollection,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> StreamCollectionBuilder<'a> {
fn new(collection: &'a crate::StreamCollection) -> Self {
skip_assert_initialized!();
@ -2672,20 +2672,20 @@ impl<'a> StreamCollectionBuilder<'a> {
});
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct StreamsSelectedBuilder<'a> {
builder: MessageBuilder<'a>,
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
collection: &'a crate::StreamCollection,
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
streams: Option<&'a [&'a crate::Stream]>,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> StreamsSelectedBuilder<'a> {
fn new(collection: &'a crate::StreamCollection) -> Self {
skip_assert_initialized!();
@ -2714,8 +2714,8 @@ impl<'a> StreamsSelectedBuilder<'a> {
});
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
pub struct RedirectBuilder<'a> {
builder: MessageBuilder<'a>,
location: &'a str,
@ -2725,8 +2725,8 @@ pub struct RedirectBuilder<'a> {
entries: Option<&'a [(&'a str, Option<&'a TagList>, Option<&'a Structure>)]>,
}
#[cfg(any(feature = "v1_10", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_10")))]
#[cfg(any(feature = "v1_10", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))]
impl<'a> RedirectBuilder<'a> {
fn new(location: &'a str) -> Self {
skip_assert_initialized!();
@ -2798,16 +2798,16 @@ impl<'a> RedirectBuilder<'a> {
});
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub struct DeviceChangedBuilder<'a> {
builder: MessageBuilder<'a>,
device: &'a crate::Device,
changed_device: &'a crate::Device,
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl<'a> DeviceChangedBuilder<'a> {
fn new(device: &'a crate::Device, changed_device: &'a crate::Device) -> Self {
skip_assert_initialized!();

View file

@ -12,18 +12,18 @@ use std::ops;
use crate::Buffer;
use crate::BufferRef;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use crate::Caps;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use crate::CapsRef;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use crate::ClockTime;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use glib::translate::ToGlib;
use glib::translate::{from_glib, from_glib_none, FromGlib, ToGlibPtr};
@ -71,8 +71,8 @@ pub unsafe trait MetaAPI: Sync + Send + Sized {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
#[derive(Debug, Clone, Copy, PartialOrd, Ord, PartialEq, Eq)]
pub struct MetaSeqnum(u64);
@ -152,8 +152,8 @@ impl<'a, T: MetaAPI> MetaRef<'a, T> {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_seqnum(&self) -> MetaSeqnum {
unsafe {
let meta = self.meta as *const _ as *const ffi::GstMeta;
@ -188,8 +188,8 @@ impl<'a, T: MetaAPI, U> MetaRefMut<'a, T, U> {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_seqnum(&self) -> u64 {
unsafe {
let meta = self.meta as *const _ as *const ffi::GstMeta;
@ -344,20 +344,20 @@ impl fmt::Debug for ProtectionMeta {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
#[repr(transparent)]
pub struct ReferenceTimestampMeta(ffi::GstReferenceTimestampMeta);
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
unsafe impl Send for ReferenceTimestampMeta {}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
unsafe impl Sync for ReferenceTimestampMeta {}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
impl ReferenceTimestampMeta {
pub fn add<'a>(
buffer: &'a mut BufferRef,
@ -395,8 +395,8 @@ impl ReferenceTimestampMeta {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
unsafe impl MetaAPI for ReferenceTimestampMeta {
type GstType = ffi::GstReferenceTimestampMeta;
@ -405,8 +405,8 @@ unsafe impl MetaAPI for ReferenceTimestampMeta {
}
}
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
impl fmt::Debug for ReferenceTimestampMeta {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
f.debug_struct("ReferenceTimestampMeta")

View file

@ -7,16 +7,16 @@
// except according to those terms.
use crate::PadTemplate;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use crate::StaticPadTemplate;
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
use glib::translate::*;
impl PadTemplate {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
pub fn from_static_pad_template_with_gtype(
pad_template: &StaticPadTemplate,
pad_type: glib::types::Type,

View file

@ -9,8 +9,8 @@
use glib::translate::*;
pub trait GstParamSpecExt {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
fn array(
name: &str,
nick: &str,
@ -31,8 +31,8 @@ pub trait GstParamSpecExt {
}
impl GstParamSpecExt for glib::ParamSpec {
#[cfg(any(feature = "v1_14", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_14")))]
#[cfg(any(feature = "v1_14", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))]
fn array(
name: &str,
nick: &str,

View file

@ -1303,8 +1303,8 @@ impl<T: AsMutPtr> Context<T> {
declare_concrete_query!(Bitrate, T);
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl Bitrate<Query> {
pub fn new() -> Self {
assert_initialized_main_thread!();
@ -1312,8 +1312,8 @@ impl Bitrate<Query> {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
impl Default for Bitrate<Query> {
fn default() -> Self {
Self::new()
@ -1321,8 +1321,8 @@ impl Default for Bitrate<Query> {
}
impl<T: AsPtr> Bitrate<T> {
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn get_bitrate(&self) -> u32 {
unsafe {
let mut bitrate = mem::MaybeUninit::uninit();
@ -1333,8 +1333,8 @@ impl<T: AsPtr> Bitrate<T> {
}
impl<T: AsMutPtr> Bitrate<T> {
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_bitrate(&mut self, bitrate: u32) {
unsafe {
ffi::gst_query_set_bitrate(self.0.as_mut_ptr(), bitrate);

View file

@ -178,32 +178,32 @@ impl SampleRef {
}
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_buffer(&mut self, buffer: Option<&Buffer>) {
unsafe { ffi::gst_sample_set_buffer(self.as_mut_ptr(), buffer.to_glib_none().0) }
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_buffer_list(&mut self, buffer_list: Option<&BufferList>) {
unsafe { ffi::gst_sample_set_buffer_list(self.as_mut_ptr(), buffer_list.to_glib_none().0) }
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_caps(&mut self, caps: Option<&Caps>) {
unsafe { ffi::gst_sample_set_caps(self.as_mut_ptr(), caps.to_glib_none().0) }
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_segment(&mut self, segment: Option<&Segment>) {
unsafe { ffi::gst_sample_set_segment(self.as_mut_ptr(), segment.to_glib_none().0) }
}
#[cfg(any(feature = "v1_16", all(not(doctest), doc)))]
#[cfg_attr(all(not(doctest), doc), doc(cfg(feature = "v1_16")))]
#[cfg(any(feature = "v1_16", feature = "dox"))]
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))]
pub fn set_info(&mut self, info: Option<Structure>) {
unsafe {
ffi::gst_sample_set_info(