From 540062b97cf2ed5a04fac97f5853c380e68216f4 Mon Sep 17 00:00:00 2001 From: Marijn Suijten Date: Wed, 19 May 2021 22:35:47 +0200 Subject: [PATCH] Add missing doc aliases to manual code Using the same script as [1], called with: python3 add_doc_alias.py gstreamer*/**/src [1]: https://github.com/gtk-rs/gtk-rs-core/pull/83 --- gstreamer-app/src/app_sink.rs | 1 + gstreamer-app/src/app_src.rs | 5 ++ gstreamer-audio/src/audio_channel_position.rs | 8 +++ gstreamer-audio/src/audio_decoder.rs | 5 ++ gstreamer-audio/src/audio_encoder.rs | 5 ++ gstreamer-audio/src/audio_format.rs | 2 + gstreamer-audio/src/audio_format_info.rs | 2 + gstreamer-audio/src/audio_info.rs | 4 ++ gstreamer-audio/src/audio_meta.rs | 4 ++ gstreamer-audio/src/audio_stream_align.rs | 1 + gstreamer-audio/src/functions.rs | 2 + gstreamer-base/src/adapter.rs | 15 +++++ gstreamer-base/src/aggregator.rs | 5 ++ gstreamer-base/src/base_parse.rs | 4 ++ gstreamer-base/src/base_sink.rs | 1 + gstreamer-base/src/base_src.rs | 3 + gstreamer-base/src/base_transform.rs | 1 + gstreamer-base/src/flow_combiner.rs | 7 ++ gstreamer-base/src/functions.rs | 4 ++ gstreamer-base/src/utils.rs | 1 + gstreamer-check/src/harness.rs | 65 +++++++++++++++++++ gstreamer-check/src/test_clock.rs | 8 +++ gstreamer-editing-services/src/lib.rs | 1 + .../src/timeline_element.rs | 2 + gstreamer-gl/src/context.rs | 2 + gstreamer-gl/src/gl_context.rs | 4 ++ gstreamer-gl/src/gl_sync_meta.rs | 5 ++ gstreamer-net/src/net_address_meta.rs | 2 + gstreamer-net/src/net_client_clock.rs | 1 + gstreamer-net/src/net_time_provider.rs | 1 + gstreamer-net/src/ntp_clock.rs | 1 + gstreamer-net/src/ptp_clock.rs | 1 + .../src/discoverer_video_info.rs | 4 ++ gstreamer-pbutils/src/encoding_profile.rs | 16 +++++ gstreamer-pbutils/src/functions.rs | 4 ++ gstreamer-player/src/config.rs | 4 ++ gstreamer-player/src/player.rs | 3 + ...player_g_main_context_signal_dispatcher.rs | 1 + gstreamer-player/src/player_video_info.rs | 2 + .../player_video_overlay_video_renderer.rs | 1 + gstreamer-rtp/src/rtp_buffer.rs | 20 ++++++ .../src/rtsp_address_pool.rs | 1 + gstreamer-rtsp-server/src/rtsp_auth.rs | 1 + gstreamer-rtsp-server/src/rtsp_client.rs | 1 + gstreamer-rtsp-server/src/rtsp_media.rs | 1 + .../src/rtsp_media_factory.rs | 1 + gstreamer-rtsp-server/src/rtsp_server.rs | 1 + .../src/rtsp_session_pool.rs | 1 + gstreamer-rtsp-server/src/rtsp_thread.rs | 3 + gstreamer-rtsp-server/src/rtsp_token.rs | 4 ++ gstreamer-sdp/src/sdp_media.rs | 42 ++++++++++++ gstreamer-sdp/src/sdp_message.rs | 61 +++++++++++++++++ gstreamer-video/src/functions.rs | 3 + gstreamer-video/src/video_buffer_pool.rs | 2 + gstreamer-video/src/video_converter.rs | 4 ++ gstreamer-video/src/video_decoder.rs | 13 ++++ gstreamer-video/src/video_encoder.rs | 12 ++++ gstreamer-video/src/video_event.rs | 4 ++ gstreamer-video/src/video_format.rs | 2 + gstreamer-video/src/video_frame.rs | 4 ++ gstreamer-video/src/video_info.rs | 12 ++++ gstreamer-video/src/video_meta.rs | 21 ++++++ gstreamer-video/src/video_overlay.rs | 1 + .../src/video_overlay_composition.rs | 18 +++++ gstreamer-video/src/video_time_code.rs | 12 ++++ .../src/video_time_code_interval.rs | 1 + gstreamer-webrtc/src/web_rtc_data_channel.rs | 1 + .../src/web_rtc_session_description.rs | 1 + gstreamer/src/bin.rs | 7 ++ gstreamer/src/buffer.rs | 27 ++++++++ gstreamer/src/buffer_pool.rs | 13 ++++ gstreamer/src/bufferlist.rs | 9 +++ gstreamer/src/bus.rs | 4 ++ gstreamer/src/bus_unix.rs | 1 + gstreamer/src/bus_windows.rs | 1 + gstreamer/src/caps.rs | 32 +++++++++ gstreamer/src/caps_features.rs | 10 +++ gstreamer/src/clock.rs | 13 ++++ gstreamer/src/context.rs | 5 ++ gstreamer/src/control_binding.rs | 1 + gstreamer/src/control_source.rs | 1 + gstreamer/src/date_time.rs | 12 ++++ gstreamer/src/device_monitor.rs | 3 + gstreamer/src/device_provider.rs | 2 + gstreamer/src/element.rs | 21 ++++++ gstreamer/src/enums.rs | 1 + gstreamer/src/event.rs | 18 +++++ gstreamer/src/functions.rs | 5 ++ gstreamer/src/ghost_pad.rs | 2 + gstreamer/src/iterator.rs | 7 ++ gstreamer/src/lib.rs | 1 + gstreamer/src/log.rs | 10 +++ gstreamer/src/memory.rs | 4 ++ gstreamer/src/message.rs | 24 +++++++ gstreamer/src/meta.rs | 9 +++ gstreamer/src/miniobject.rs | 2 + gstreamer/src/object.rs | 1 + gstreamer/src/pad.rs | 25 +++++++ gstreamer/src/pad_template.rs | 1 + gstreamer/src/parse_context.rs | 2 + gstreamer/src/plugin.rs | 2 + gstreamer/src/plugin_feature.rs | 3 + gstreamer/src/promise.rs | 7 ++ gstreamer/src/proxy_pad.rs | 4 ++ gstreamer/src/query.rs | 53 +++++++++++++++ gstreamer/src/sample.rs | 10 +++ gstreamer/src/segment.rs | 13 ++++ gstreamer/src/static_caps.rs | 1 + gstreamer/src/static_pad_template.rs | 2 + gstreamer/src/stream.rs | 1 + gstreamer/src/stream_collection.rs | 1 + gstreamer/src/structure.rs | 20 ++++++ gstreamer/src/tag_setter.rs | 1 + gstreamer/src/tags.rs | 17 +++++ gstreamer/src/toc.rs | 23 +++++++ gstreamer/src/typefind.rs | 5 ++ gstreamer/src/utils.rs | 1 + gstreamer/src/value.rs | 13 ++++ 118 files changed, 907 insertions(+) diff --git a/gstreamer-app/src/app_sink.rs b/gstreamer-app/src/app_sink.rs index 745e5b1c6..16ae91ca4 100644 --- a/gstreamer-app/src/app_sink.rs +++ b/gstreamer-app/src/app_sink.rs @@ -236,6 +236,7 @@ unsafe extern "C" fn destroy_callbacks(ptr: gpointer) { } impl AppSink { + #[doc(alias = "gst_app_sink_set_callbacks")] pub fn set_callbacks(&self, callbacks: AppSinkCallbacks) { use once_cell::sync::Lazy; static SET_ONCE_QUARK: Lazy = diff --git a/gstreamer-app/src/app_src.rs b/gstreamer-app/src/app_src.rs index 901165a48..53e544464 100644 --- a/gstreamer-app/src/app_src.rs +++ b/gstreamer-app/src/app_src.rs @@ -207,6 +207,7 @@ unsafe extern "C" fn destroy_callbacks(ptr: gpointer) { } impl AppSrc { + #[doc(alias = "gst_app_src_push_buffer")] pub fn push_buffer(&self, buffer: gst::Buffer) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_app_src_push_buffer( @@ -218,6 +219,7 @@ impl AppSrc { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_app_src_push_buffer_list")] pub fn push_buffer_list( &self, list: gst::BufferList, @@ -230,6 +232,7 @@ impl AppSrc { } } + #[doc(alias = "gst_app_src_set_callbacks")] pub fn set_callbacks(&self, callbacks: AppSrcCallbacks) { use once_cell::sync::Lazy; static SET_ONCE_QUARK: Lazy = @@ -262,6 +265,7 @@ impl AppSrc { } } + #[doc(alias = "gst_app_src_set_latency")] pub fn set_latency(&self, min: gst::ClockTime, max: gst::ClockTime) { unsafe { ffi::gst_app_src_set_latency(self.to_glib_none().0, min.into_glib(), max.into_glib()); @@ -269,6 +273,7 @@ impl AppSrc { } #[doc(alias = "get_latency")] + #[doc(alias = "gst_app_src_get_latency")] pub fn latency(&self) -> (gst::ClockTime, gst::ClockTime) { unsafe { let mut min = mem::MaybeUninit::uninit(); diff --git a/gstreamer-audio/src/audio_channel_position.rs b/gstreamer-audio/src/audio_channel_position.rs index 6394779d5..120d67c78 100644 --- a/gstreamer-audio/src/audio_channel_position.rs +++ b/gstreamer-audio/src/audio_channel_position.rs @@ -16,6 +16,7 @@ impl AudioChannelPosition { 1 << (pos as u32) } + #[doc(alias = "gst_audio_channel_positions_to_mask")] pub fn positions_to_mask( positions: &[Self], force_order: bool, @@ -53,6 +54,7 @@ impl AudioChannelPosition { } } + #[doc(alias = "gst_audio_channel_positions_from_mask")] pub fn positions_from_mask(mask: u64, positions: &mut [Self]) -> Result<(), glib::BoolError> { assert_initialized_main_thread!(); @@ -83,6 +85,7 @@ impl AudioChannelPosition { } } + #[doc(alias = "gst_audio_channel_positions_to_valid_order")] pub fn positions_to_valid_order(positions: &mut [Self]) -> Result<(), glib::BoolError> { assert_initialized_main_thread!(); @@ -119,12 +122,14 @@ impl AudioChannelPosition { } #[doc(alias = "get_fallback_mask")] + #[doc(alias = "gst_audio_channel_get_fallback_mask")] pub fn fallback_mask(channels: u32) -> u64 { assert_initialized_main_thread!(); unsafe { ffi::gst_audio_channel_get_fallback_mask(channels as i32) } } + #[doc(alias = "gst_audio_check_valid_channel_positions")] pub fn check_valid_channel_positions(positions: &[Self], force_order: bool) -> bool { assert_initialized_main_thread!(); @@ -151,6 +156,7 @@ impl AudioChannelPosition { } } +#[doc(alias = "gst_audio_buffer_reorder_channels")] pub fn buffer_reorder_channels( buffer: &mut gst::BufferRef, format: crate::AudioFormat, @@ -200,6 +206,7 @@ pub fn buffer_reorder_channels( } } +#[doc(alias = "gst_audio_reorder_channels")] pub fn reorder_channels( data: &mut [u8], format: crate::AudioFormat, @@ -251,6 +258,7 @@ pub fn reorder_channels( } #[doc(alias = "get_channel_reorder_map")] +#[doc(alias = "gst_audio_get_channel_reorder_map")] pub fn channel_reorder_map( from: &[AudioChannelPosition], to: &[AudioChannelPosition], diff --git a/gstreamer-audio/src/audio_decoder.rs b/gstreamer-audio/src/audio_decoder.rs index 5b2f43878..091ded81f 100644 --- a/gstreamer-audio/src/audio_decoder.rs +++ b/gstreamer-audio/src/audio_decoder.rs @@ -76,6 +76,7 @@ impl> AudioDecoderExtManual for O { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_audio_decoder_finish_subframe")] fn finish_subframe( &self, buffer: Option, @@ -88,6 +89,7 @@ impl> AudioDecoderExtManual for O { } } + #[doc(alias = "gst_audio_decoder_negotiate")] fn negotiate(&self) -> Result<(), gst::FlowError> { unsafe { let ret = from_glib(ffi::gst_audio_decoder_negotiate( @@ -103,6 +105,7 @@ impl> AudioDecoderExtManual for O { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_audio_decoder_set_output_caps")] fn set_output_caps(&self, caps: &gst::Caps) -> Result<(), gst::FlowError> { unsafe { let ret = from_glib(ffi::gst_audio_decoder_set_output_caps( @@ -117,6 +120,7 @@ impl> AudioDecoderExtManual for O { } } + #[doc(alias = "gst_audio_decoder_set_output_format")] fn set_output_format(&self, info: &AudioInfo) -> Result<(), gst::FlowError> { unsafe { let ret = from_glib(ffi::gst_audio_decoder_set_output_format( @@ -131,6 +135,7 @@ impl> AudioDecoderExtManual for O { } } + #[doc(alias = "gst_audio_decoder_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams) { unsafe { let mut allocator = ptr::null_mut(); diff --git a/gstreamer-audio/src/audio_encoder.rs b/gstreamer-audio/src/audio_encoder.rs index 1989eb7d0..5a1762bee 100644 --- a/gstreamer-audio/src/audio_encoder.rs +++ b/gstreamer-audio/src/audio_encoder.rs @@ -7,20 +7,25 @@ use std::mem; use std::ptr; pub trait AudioEncoderExtManual: 'static { + #[doc(alias = "gst_audio_encoder_finish_frame")] fn finish_frame( &self, buffer: Option, frames: i32, ) -> Result; + #[doc(alias = "gst_audio_encoder_negotiate")] fn negotiate(&self) -> Result<(), gst::FlowError>; + #[doc(alias = "gst_audio_encoder_set_output_format")] fn set_output_format(&self, caps: &gst::Caps) -> Result<(), gst::FlowError>; #[doc(alias = "get_allocator")] + #[doc(alias = "gst_audio_encoder_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams); #[doc(alias = "get_latency")] + #[doc(alias = "gst_audio_encoder_get_latency")] fn latency(&self) -> (gst::ClockTime, gst::ClockTime); } diff --git a/gstreamer-audio/src/audio_format.rs b/gstreamer-audio/src/audio_format.rs index f9b95ec16..b81452473 100644 --- a/gstreamer-audio/src/audio_format.rs +++ b/gstreamer-audio/src/audio_format.rs @@ -94,6 +94,7 @@ pub static AUDIO_FORMATS_ALL: Lazy> = Lazy::new(|| { }); impl crate::AudioFormat { + #[doc(alias = "gst_audio_format_build_integer")] pub fn build_integer( sign: bool, endianness: crate::AudioEndianness, @@ -112,6 +113,7 @@ impl crate::AudioFormat { } } + #[doc(alias = "gst_audio_format_to_string")] pub fn to_str<'a>(self) -> &'a str { if self == Self::Unknown { return "UNKNOWN"; diff --git a/gstreamer-audio/src/audio_format_info.rs b/gstreamer-audio/src/audio_format_info.rs index 8605650bf..b0edba958 100644 --- a/gstreamer-audio/src/audio_format_info.rs +++ b/gstreamer-audio/src/audio_format_info.rs @@ -158,6 +158,8 @@ impl AudioFormatInfo { } } + #[doc(alias = "gst_audio_format_info_fill_silence")] + #[doc(alias = "gst_audio_format_fill_silence")] pub fn fill_silence(&self, dest: &mut [u8]) { let self_width = self.width() as usize; diff --git a/gstreamer-audio/src/audio_info.rs b/gstreamer-audio/src/audio_info.rs index 50601804f..5ba900d02 100644 --- a/gstreamer-audio/src/audio_info.rs +++ b/gstreamer-audio/src/audio_info.rs @@ -142,6 +142,7 @@ impl AudioInfo { !self.0.finfo.is_null() && self.0.channels > 0 && self.0.rate > 0 && self.0.bpf > 0 } + #[doc(alias = "gst_audio_info_from_caps")] pub fn from_caps(caps: &gst::CapsRef) -> Result { skip_assert_initialized!(); @@ -160,6 +161,7 @@ impl AudioInfo { } } + #[doc(alias = "gst_audio_info_to_caps")] pub fn to_caps(&self) -> Result { unsafe { let result = from_glib_full(ffi::gst_audio_info_to_caps(&self.0)); @@ -170,6 +172,7 @@ impl AudioInfo { } } + #[doc(alias = "gst_audio_info_convert")] pub fn convert, U: gst::SpecificFormattedValue>( &self, src_val: V, @@ -308,6 +311,7 @@ impl Clone for AudioInfo { } impl PartialEq for AudioInfo { + #[doc(alias = "gst_audio_info_is_equal")] fn eq(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_audio_info_is_equal(&self.0, &other.0)) } } diff --git a/gstreamer-audio/src/audio_meta.rs b/gstreamer-audio/src/audio_meta.rs index b40f5ab4d..a2422f997 100644 --- a/gstreamer-audio/src/audio_meta.rs +++ b/gstreamer-audio/src/audio_meta.rs @@ -21,6 +21,7 @@ unsafe impl Send for AudioClippingMeta {} unsafe impl Sync for AudioClippingMeta {} impl AudioClippingMeta { + #[doc(alias = "gst_buffer_add_audio_clipping_meta")] pub fn add>( buffer: &mut gst::BufferRef, start: V, @@ -56,6 +57,7 @@ impl AudioClippingMeta { unsafe impl MetaAPI for AudioClippingMeta { type GstType = ffi::GstAudioClippingMeta; + #[doc(alias = "gst_audio_clipping_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_audio_clipping_meta_api_get_type()) } } @@ -85,6 +87,7 @@ unsafe impl Sync for AudioMeta {} #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] impl AudioMeta { + #[doc(alias = "gst_buffer_add_audio_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, info: &crate::AudioInfo, @@ -196,6 +199,7 @@ impl AudioMeta { unsafe impl MetaAPI for AudioMeta { type GstType = ffi::GstAudioMeta; + #[doc(alias = "gst_audio_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_audio_meta_api_get_type()) } } diff --git a/gstreamer-audio/src/audio_stream_align.rs b/gstreamer-audio/src/audio_stream_align.rs index bf9e7d8a9..fcab75413 100644 --- a/gstreamer-audio/src/audio_stream_align.rs +++ b/gstreamer-audio/src/audio_stream_align.rs @@ -8,6 +8,7 @@ use std::mem; impl AudioStreamAlign { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_audio_stream_align_process")] pub fn process( &mut self, discont: bool, diff --git a/gstreamer-audio/src/functions.rs b/gstreamer-audio/src/functions.rs index 1f86452fe..3467d095c 100644 --- a/gstreamer-audio/src/functions.rs +++ b/gstreamer-audio/src/functions.rs @@ -5,6 +5,7 @@ use glib::ToSendValue; use std::i32; +#[doc(alias = "gst_audio_buffer_clip")] pub fn audio_buffer_clip( buffer: gst::Buffer, segment: &gst::Segment, @@ -25,6 +26,7 @@ pub fn audio_buffer_clip( #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] +#[doc(alias = "gst_audio_buffer_truncate")] pub fn audio_buffer_truncate( buffer: gst::Buffer, bpf: u32, diff --git a/gstreamer-base/src/adapter.rs b/gstreamer-base/src/adapter.rs index 31bc27376..870d48720 100644 --- a/gstreamer-base/src/adapter.rs +++ b/gstreamer-base/src/adapter.rs @@ -7,6 +7,7 @@ use std::mem; use std::ops; impl Adapter { + #[doc(alias = "gst_adapter_copy")] pub fn copy(&self, offset: usize, dest: &mut [u8]) -> Result<(), glib::BoolError> { assert!( offset @@ -32,6 +33,7 @@ impl Adapter { Ok(()) } + #[doc(alias = "gst_adapter_copy_bytes")] pub fn copy_bytes(&self, offset: usize, size: usize) -> Result { assert!(offset.checked_add(size).map(|end| end <= self.available()) == Some(true)); @@ -48,6 +50,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_flush")] pub fn flush(&self, flush: usize) { assert!(flush <= self.available()); @@ -61,6 +64,7 @@ impl Adapter { } #[doc(alias = "get_buffer")] + #[doc(alias = "gst_adapter_get_buffer")] pub fn buffer(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -72,6 +76,7 @@ impl Adapter { } #[doc(alias = "get_buffer_fast")] + #[doc(alias = "gst_adapter_get_buffer_fast")] pub fn buffer_fast(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -86,6 +91,7 @@ impl Adapter { } #[doc(alias = "get_buffer_list")] + #[doc(alias = "gst_adapter_get_buffer_list")] pub fn buffer_list(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -100,6 +106,7 @@ impl Adapter { } #[doc(alias = "get_list")] + #[doc(alias = "gst_adapter_get_list")] pub fn list(&self, nbytes: usize) -> Result, glib::BoolError> { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -111,6 +118,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_masked_scan_uint32")] pub fn masked_scan_uint32( &self, mask: u32, @@ -139,6 +147,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_masked_scan_uint32_peek")] pub fn masked_scan_uint32_peek( &self, mask: u32, @@ -171,6 +180,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_take_buffer")] pub fn take_buffer(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -181,6 +191,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_take_buffer_fast")] pub fn take_buffer_fast(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -194,6 +205,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_take_buffer_list")] pub fn take_buffer_list(&self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -207,6 +219,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_take_list")] pub fn take_list(&self, nbytes: usize) -> Result, glib::BoolError> { assert!(nbytes <= self.available()); assert!(nbytes != 0); @@ -218,6 +231,7 @@ impl Adapter { } } + #[doc(alias = "gst_adapter_push")] pub fn push(&self, buf: gst::Buffer) { unsafe { ffi::gst_adapter_push(self.to_glib_none().0, buf.into_ptr()); @@ -394,6 +408,7 @@ impl UniqueAdapter { self.0.push(buf); } + #[doc(alias = "gst_adapter_map")] pub fn map(&mut self, nbytes: usize) -> Result { assert!(nbytes <= self.available()); assert!(nbytes != 0); diff --git a/gstreamer-base/src/aggregator.rs b/gstreamer-base/src/aggregator.rs index 25c236d10..f7dddd4c8 100644 --- a/gstreamer-base/src/aggregator.rs +++ b/gstreamer-base/src/aggregator.rs @@ -20,12 +20,15 @@ use std::ptr; pub trait AggregatorExtManual: 'static { #[doc(alias = "get_allocator")] + #[doc(alias = "gst_aggregator_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams); + #[doc(alias = "gst_aggregator_finish_buffer")] fn finish_buffer(&self, buffer: gst::Buffer) -> Result; #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_aggregator_finish_buffer_list")] fn finish_buffer_list( &self, bufferlist: gst::BufferList, @@ -51,10 +54,12 @@ pub trait AggregatorExtManual: 'static { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_aggregator_update_segment")] fn update_segment(&self, segment: &gst::FormattedSegment); #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_aggregator_selected_samples")] fn selected_samples( &self, pts: gst::ClockTime, diff --git a/gstreamer-base/src/base_parse.rs b/gstreamer-base/src/base_parse.rs index b7f82d117..b5a9411fb 100644 --- a/gstreamer-base/src/base_parse.rs +++ b/gstreamer-base/src/base_parse.rs @@ -14,9 +14,12 @@ pub trait BaseParseExtManual: 'static { #[doc(alias = "get_src_pad")] fn src_pad(&self) -> gst::Pad; + #[doc(alias = "gst_base_parse_set_duration")] fn set_duration>(&self, duration: V, interval: u32); + #[doc(alias = "gst_base_parse_set_frame_rate")] fn set_frame_rate(&self, fps: gst::Fraction, lead_in: u32, lead_out: u32); + #[doc(alias = "gst_base_parse_convert_default")] fn convert_default, U: gst::SpecificFormattedValue>( &self, src_val: V, @@ -27,6 +30,7 @@ pub trait BaseParseExtManual: 'static { dest_format: gst::Format, ) -> Option; + #[doc(alias = "gst_base_parse_finish_frame")] fn finish_frame( &self, frame: BaseParseFrame, diff --git a/gstreamer-base/src/base_sink.rs b/gstreamer-base/src/base_sink.rs index 8d91f5bf4..b55f07e1d 100644 --- a/gstreamer-base/src/base_sink.rs +++ b/gstreamer-base/src/base_sink.rs @@ -9,6 +9,7 @@ pub trait BaseSinkExtManual: 'static { #[doc(alias = "get_segment")] fn segment(&self) -> gst::Segment; + #[doc(alias = "gst_base_sink_query_latency")] fn query_latency( &self, ) -> Result<(bool, bool, gst::ClockTime, gst::ClockTime), glib::BoolError>; diff --git a/gstreamer-base/src/base_src.rs b/gstreamer-base/src/base_src.rs index 2b1ace3a7..15aca9b8e 100644 --- a/gstreamer-base/src/base_src.rs +++ b/gstreamer-base/src/base_src.rs @@ -9,15 +9,18 @@ use crate::BaseSrc; pub trait BaseSrcExtManual: 'static { #[doc(alias = "get_allocator")] + #[doc(alias = "gst_base_src_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams); #[doc(alias = "get_segment")] fn segment(&self) -> gst::Segment; + #[doc(alias = "gst_base_src_query_latency")] fn query_latency(&self) -> Result<(bool, gst::ClockTime, gst::ClockTime), glib::BoolError>; #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_base_src_new_segment")] fn new_segment(&self, segment: &gst::Segment) -> Result<(), glib::BoolError>; } diff --git a/gstreamer-base/src/base_transform.rs b/gstreamer-base/src/base_transform.rs index 187b0b0a0..a3abfa043 100644 --- a/gstreamer-base/src/base_transform.rs +++ b/gstreamer-base/src/base_transform.rs @@ -8,6 +8,7 @@ use std::ptr; pub trait BaseTransformExtManual: 'static { #[doc(alias = "get_allocator")] + #[doc(alias = "gst_base_transform_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams); #[doc(alias = "get_segment")] diff --git a/gstreamer-base/src/flow_combiner.rs b/gstreamer-base/src/flow_combiner.rs index 2628035cd..9e28f873c 100644 --- a/gstreamer-base/src/flow_combiner.rs +++ b/gstreamer-base/src/flow_combiner.rs @@ -31,35 +31,41 @@ glib::wrapper! { } impl FlowCombiner { + #[doc(alias = "gst_flow_combiner_new")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_flow_combiner_new()) } } + #[doc(alias = "gst_flow_combiner_add_pad")] pub fn add_pad>(&self, pad: &P) { unsafe { ffi::gst_flow_combiner_add_pad(self.to_glib_none().0, pad.as_ref().to_glib_none().0); } } + #[doc(alias = "gst_flow_combiner_clear")] pub fn clear(&self) { unsafe { ffi::gst_flow_combiner_clear(self.to_glib_none().0); } } + #[doc(alias = "gst_flow_combiner_remove_pad")] pub fn remove_pad>(&self, pad: &P) { unsafe { ffi::gst_flow_combiner_remove_pad(self.to_glib_none().0, pad.as_ref().to_glib_none().0); } } + #[doc(alias = "gst_flow_combiner_reset")] pub fn reset(&self) { unsafe { ffi::gst_flow_combiner_reset(self.to_glib_none().0); } } + #[doc(alias = "gst_flow_combiner_update_flow")] pub fn update_flow>( &self, fret: FRet, @@ -73,6 +79,7 @@ impl FlowCombiner { } } + #[doc(alias = "gst_flow_combiner_update_pad_flow")] pub fn update_pad_flow, FRet: Into>( &self, pad: &P, diff --git a/gstreamer-base/src/functions.rs b/gstreamer-base/src/functions.rs index 7baa9d597..7a9938731 100644 --- a/gstreamer-base/src/functions.rs +++ b/gstreamer-base/src/functions.rs @@ -4,6 +4,7 @@ use glib::prelude::*; use glib::translate::*; use std::mem; +#[doc(alias = "gst_type_find_helper_for_data")] pub fn type_find_helper_for_data, R: AsRef<[u8]>>( obj: Option<&P>, data: R, @@ -29,6 +30,7 @@ pub fn type_find_helper_for_data, R: AsRef<[u8]>>( #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] +#[doc(alias = "gst_type_find_helper_for_data_with_extension")] pub fn type_find_helper_for_data_with_extension, R: AsRef<[u8]>>( obj: Option<&P>, data: R, @@ -54,6 +56,7 @@ pub fn type_find_helper_for_data_with_extension, R: AsRef<[u } } +#[doc(alias = "gst_type_find_helper_for_buffer")] pub fn type_find_helper_for_buffer>( obj: Option<&P>, buf: &gst::Buffer, @@ -76,6 +79,7 @@ pub fn type_find_helper_for_buffer>( #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] +#[doc(alias = "gst_type_find_helper_for_buffer_with_extension")] pub fn type_find_helper_for_buffer_with_extension>( obj: Option<&P>, buf: &gst::Buffer, diff --git a/gstreamer-base/src/utils.rs b/gstreamer-base/src/utils.rs index 8aa113cfd..8ffc2afb3 100644 --- a/gstreamer-base/src/utils.rs +++ b/gstreamer-base/src/utils.rs @@ -7,6 +7,7 @@ pub struct MutexGuard<'a>(&'a glib::ffi::GMutex); impl<'a> MutexGuard<'a> { #[allow(clippy::trivially_copy_pass_by_ref)] + #[doc(alias = "g_mutex_lock")] pub fn lock(mutex: &'a glib::ffi::GMutex) -> Self { skip_assert_initialized!(); unsafe { diff --git a/gstreamer-check/src/harness.rs b/gstreamer-check/src/harness.rs index 6bfec4006..8f2a40786 100644 --- a/gstreamer-check/src/harness.rs +++ b/gstreamer-check/src/harness.rs @@ -24,6 +24,7 @@ unsafe impl Send for Harness {} unsafe impl Sync for Harness {} impl Harness { + #[doc(alias = "gst_harness_add_element_full")] pub fn add_element_full>( &mut self, element: &P, @@ -46,6 +47,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_element_sink_pad")] pub fn add_element_sink_pad>(&mut self, sinkpad: &P) { unsafe { ffi::gst_harness_add_element_sink_pad( @@ -55,12 +57,14 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_element_src_pad")] pub fn add_element_src_pad>(&mut self, srcpad: &P) { unsafe { ffi::gst_harness_add_element_src_pad(self.0.as_ptr(), srcpad.as_ref().to_glib_none().0); } } + #[doc(alias = "gst_harness_add_parse")] pub fn add_parse(&mut self, launchline: &str) { unsafe { ffi::gst_harness_add_parse(self.0.as_ptr(), launchline.to_glib_none().0); @@ -85,6 +89,7 @@ impl Harness { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_harness_add_propose_allocation_meta")] pub fn add_propose_allocation_meta( &mut self, api: glib::types::Type, @@ -96,12 +101,14 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_sink")] pub fn add_sink(&mut self, sink_element_name: &str) { unsafe { ffi::gst_harness_add_sink(self.0.as_ptr(), sink_element_name.to_glib_none().0); } } + #[doc(alias = "gst_harness_add_sink_harness")] pub fn add_sink_harness(&mut self, sink_harness: Harness) { unsafe { let sink_harness = mem::ManuallyDrop::new(sink_harness); @@ -109,12 +116,14 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_sink_parse")] pub fn add_sink_parse(&mut self, launchline: &str) { unsafe { ffi::gst_harness_add_sink_parse(self.0.as_ptr(), launchline.to_glib_none().0); } } + #[doc(alias = "gst_harness_add_src")] pub fn add_src(&mut self, src_element_name: &str, has_clock_wait: bool) { unsafe { ffi::gst_harness_add_src( @@ -125,6 +134,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_src_harness")] pub fn add_src_harness(&mut self, src_harness: Harness, has_clock_wait: bool) { unsafe { let src_harness = mem::ManuallyDrop::new(src_harness); @@ -136,6 +146,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_add_src_parse")] pub fn add_src_parse(&mut self, launchline: &str, has_clock_wait: bool) { unsafe { ffi::gst_harness_add_src_parse( @@ -146,14 +157,17 @@ impl Harness { } } + #[doc(alias = "gst_harness_buffers_in_queue")] pub fn buffers_in_queue(&self) -> u32 { unsafe { ffi::gst_harness_buffers_in_queue(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_buffers_received")] pub fn buffers_received(&self) -> u32 { unsafe { ffi::gst_harness_buffers_received(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_crank_multiple_clock_waits")] pub fn crank_multiple_clock_waits(&mut self, waits: u32) -> Result<(), glib::BoolError> { unsafe { glib::result_from_gboolean!( @@ -163,6 +177,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_crank_single_clock_wait")] pub fn crank_single_clock_wait(&mut self) -> Result<(), glib::BoolError> { unsafe { glib::result_from_gboolean!( @@ -172,6 +187,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_create_buffer")] pub fn create_buffer(&mut self, size: usize) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_create_buffer(self.0.as_ptr(), size)) @@ -179,6 +195,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_dump_to_file")] pub fn dump_to_file>(&mut self, filename: P) { let filename = filename.as_ref(); unsafe { @@ -186,14 +203,17 @@ impl Harness { } } + #[doc(alias = "gst_harness_events_in_queue")] pub fn events_in_queue(&self) -> u32 { unsafe { ffi::gst_harness_events_in_queue(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_events_received")] pub fn events_received(&self) -> u32 { unsafe { ffi::gst_harness_events_received(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_find_element")] pub fn find_element(&mut self, element_name: &str) -> Option { unsafe { // Work around https://gitlab.freedesktop.org/gstreamer/gstreamer/merge_requests/31 @@ -221,21 +241,25 @@ impl Harness { //} #[doc(alias = "get_last_pushed_timestamp")] + #[doc(alias = "gst_harness_get_last_pushed_timestamp")] pub fn last_pushed_timestamp(&self) -> gst::ClockTime { unsafe { from_glib(ffi::gst_harness_get_last_pushed_timestamp(self.0.as_ptr())) } } #[doc(alias = "get_testclock")] + #[doc(alias = "gst_harness_get_testclock")] pub fn testclock(&self) -> Option { unsafe { from_glib_full(ffi::gst_harness_get_testclock(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_play")] pub fn play(&mut self) { unsafe { ffi::gst_harness_play(self.0.as_ptr()); } } + #[doc(alias = "gst_harness_pull")] pub fn pull(&mut self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_pull(self.0.as_ptr())) @@ -245,6 +269,7 @@ impl Harness { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_harness_pull_until_eos")] pub fn pull_until_eos(&mut self) -> Result, glib::BoolError> { unsafe { let mut buffer = ptr::null_mut(); @@ -257,6 +282,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_pull_event")] pub fn pull_event(&mut self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_pull_event(self.0.as_ptr())) @@ -264,6 +290,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_pull_upstream_event")] pub fn pull_upstream_event(&mut self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_pull_upstream_event(self.0.as_ptr())) @@ -271,6 +298,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_push")] pub fn push(&mut self, buffer: gst::Buffer) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_harness_push( @@ -280,6 +308,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_push_and_pull")] pub fn push_and_pull(&mut self, buffer: gst::Buffer) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_push_and_pull( @@ -290,6 +319,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_push_event")] pub fn push_event(&mut self, event: gst::Event) -> bool { unsafe { from_glib(ffi::gst_harness_push_event( @@ -299,14 +329,17 @@ impl Harness { } } + #[doc(alias = "gst_harness_push_from_src")] pub fn push_from_src(&mut self) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_harness_push_from_src(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_push_to_sink")] pub fn push_to_sink(&mut self) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_harness_push_to_sink(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_push_upstream_event")] pub fn push_upstream_event(&mut self, event: gst::Event) -> bool { unsafe { from_glib(ffi::gst_harness_push_upstream_event( @@ -316,6 +349,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_query_latency")] pub fn query_latency(&self) -> gst::ClockTime { unsafe { from_glib(ffi::gst_harness_query_latency(self.0.as_ptr())) } } @@ -324,18 +358,21 @@ impl Harness { // unsafe { TODO: call ffi::gst_harness_set() } //} + #[doc(alias = "gst_harness_set_blocking_push_mode")] pub fn set_blocking_push_mode(&mut self) { unsafe { ffi::gst_harness_set_blocking_push_mode(self.0.as_ptr()); } } + #[doc(alias = "gst_harness_set_caps")] pub fn set_caps(&mut self, in_: gst::Caps, out: gst::Caps) { unsafe { ffi::gst_harness_set_caps(self.0.as_ptr(), in_.into_ptr(), out.into_ptr()); } } + #[doc(alias = "gst_harness_set_caps_str")] pub fn set_caps_str(&mut self, in_: &str, out: &str) { unsafe { ffi::gst_harness_set_caps_str( @@ -346,12 +383,14 @@ impl Harness { } } + #[doc(alias = "gst_harness_set_drop_buffers")] pub fn set_drop_buffers(&mut self, drop_buffers: bool) { unsafe { ffi::gst_harness_set_drop_buffers(self.0.as_ptr(), drop_buffers.into_glib()); } } + #[doc(alias = "gst_harness_set_forwarding")] pub fn set_forwarding(&mut self, forwarding: bool) { unsafe { ffi::gst_harness_set_forwarding(self.0.as_ptr(), forwarding.into_glib()); @@ -362,30 +401,35 @@ impl Harness { // unsafe { TODO: call ffi::gst_harness_set_propose_allocator() } //} + #[doc(alias = "gst_harness_set_sink_caps")] pub fn set_sink_caps(&mut self, caps: gst::Caps) { unsafe { ffi::gst_harness_set_sink_caps(self.0.as_ptr(), caps.into_ptr()); } } + #[doc(alias = "gst_harness_set_sink_caps_str")] pub fn set_sink_caps_str(&mut self, str: &str) { unsafe { ffi::gst_harness_set_sink_caps_str(self.0.as_ptr(), str.to_glib_none().0); } } + #[doc(alias = "gst_harness_set_src_caps")] pub fn set_src_caps(&mut self, caps: gst::Caps) { unsafe { ffi::gst_harness_set_src_caps(self.0.as_ptr(), caps.into_ptr()); } } + #[doc(alias = "gst_harness_set_src_caps_str")] pub fn set_src_caps_str(&mut self, str: &str) { unsafe { ffi::gst_harness_set_src_caps_str(self.0.as_ptr(), str.to_glib_none().0); } } + #[doc(alias = "gst_harness_set_time")] pub fn set_time(&mut self, time: gst::ClockTime) -> Result<(), glib::BoolError> { unsafe { glib::result_from_gboolean!( @@ -395,12 +439,14 @@ impl Harness { } } + #[doc(alias = "gst_harness_set_upstream_latency")] pub fn set_upstream_latency(&mut self, latency: gst::ClockTime) { unsafe { ffi::gst_harness_set_upstream_latency(self.0.as_ptr(), latency.into_glib()); } } + #[doc(alias = "gst_harness_sink_push_many")] pub fn sink_push_many(&mut self, pushes: u32) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_harness_sink_push_many( @@ -410,6 +456,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_src_crank_and_push_many")] pub fn src_crank_and_push_many( &mut self, cranks: u32, @@ -424,6 +471,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_src_push_event")] pub fn src_push_event(&mut self) -> bool { unsafe { from_glib(ffi::gst_harness_src_push_event(self.0.as_ptr())) } } @@ -470,6 +518,7 @@ impl Harness { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_harness_take_all_data_as_buffer")] pub fn take_all_data_as_buffer(&mut self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_take_all_data_as_buffer(self.0.as_ptr())) @@ -479,6 +528,7 @@ impl Harness { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_harness_take_all_data_as_bytes")] pub fn take_all_data_as_bytes(&mut self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_harness_take_all_data_as_bytes(self.0.as_ptr())) @@ -486,38 +536,46 @@ impl Harness { } } + #[doc(alias = "gst_harness_try_pull")] pub fn try_pull(&mut self) -> Option { unsafe { from_glib_full(ffi::gst_harness_try_pull(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_try_pull_event")] pub fn try_pull_event(&mut self) -> Option { unsafe { from_glib_full(ffi::gst_harness_try_pull_event(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_try_pull_upstream_event")] pub fn try_pull_upstream_event(&mut self) -> Option { unsafe { from_glib_full(ffi::gst_harness_try_pull_upstream_event(self.0.as_ptr())) } } + #[doc(alias = "gst_harness_upstream_events_in_queue")] pub fn upstream_events_in_queue(&self) -> u32 { unsafe { ffi::gst_harness_upstream_events_in_queue(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_upstream_events_received")] pub fn upstream_events_received(&self) -> u32 { unsafe { ffi::gst_harness_upstream_events_received(self.0.as_ptr()) } } + #[doc(alias = "gst_harness_use_systemclock")] pub fn use_systemclock(&mut self) { unsafe { ffi::gst_harness_use_systemclock(self.0.as_ptr()); } } + #[doc(alias = "gst_harness_use_testclock")] pub fn use_testclock(&mut self) { unsafe { ffi::gst_harness_use_testclock(self.0.as_ptr()); } } + #[doc(alias = "gst_harness_wait_for_clock_id_waits")] pub fn wait_for_clock_id_waits( &mut self, waits: u32, @@ -537,16 +595,19 @@ impl Harness { Harness(ptr::NonNull::new_unchecked(ptr)) } + #[doc(alias = "gst_harness_new")] pub fn new(element_name: &str) -> Harness { assert_initialized_main_thread!(); unsafe { Self::from_glib_full(ffi::gst_harness_new(element_name.to_glib_none().0)) } } + #[doc(alias = "gst_harness_new_empty")] pub fn new_empty() -> Harness { assert_initialized_main_thread!(); unsafe { Self::from_glib_full(ffi::gst_harness_new_empty()) } } + #[doc(alias = "gst_harness_new_full")] pub fn new_full>( element: &P, hsrc: Option<&gst::StaticPadTemplate>, @@ -568,11 +629,13 @@ impl Harness { } } + #[doc(alias = "gst_harness_new_parse")] pub fn new_parse(launchline: &str) -> Harness { assert_initialized_main_thread!(); unsafe { Self::from_glib_full(ffi::gst_harness_new_parse(launchline.to_glib_none().0)) } } + #[doc(alias = "gst_harness_new_with_element")] pub fn with_element>( element: &P, element_sinkpad_name: Option<&str>, @@ -590,6 +653,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_new_with_padnames")] pub fn with_padnames( element_name: &str, element_sinkpad_name: Option<&str>, @@ -607,6 +671,7 @@ impl Harness { } } + #[doc(alias = "gst_harness_new_with_templates")] pub fn with_templates( element_name: &str, hsrc: Option<&gst::StaticPadTemplate>, diff --git a/gstreamer-check/src/test_clock.rs b/gstreamer-check/src/test_clock.rs index 6d8578fae..13d96b471 100644 --- a/gstreamer-check/src/test_clock.rs +++ b/gstreamer-check/src/test_clock.rs @@ -5,6 +5,7 @@ use glib::translate::*; use std::ptr; impl TestClock { + #[doc(alias = "gst_test_clock_has_id")] pub fn has_id(&self, id: &gst::ClockId) -> bool { unsafe { from_glib(ffi::gst_test_clock_has_id( @@ -14,6 +15,7 @@ impl TestClock { } } + #[doc(alias = "gst_test_clock_peek_next_pending_id")] pub fn peek_next_pending_id(&self) -> Option { unsafe { let mut id = ptr::null_mut(); @@ -31,6 +33,7 @@ impl TestClock { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_test_clock_process_id")] pub fn process_id(&self, pending_id: &gst::ClockId) -> bool { unsafe { from_glib(ffi::gst_test_clock_process_id( @@ -40,6 +43,7 @@ impl TestClock { } } + #[doc(alias = "gst_test_clock_process_id_list")] pub fn process_id_list(&self, pending_list: &[&gst::ClockId]) -> u32 { unsafe { ffi::gst_test_clock_process_id_list( @@ -49,6 +53,7 @@ impl TestClock { } } + #[doc(alias = "gst_test_clock_process_next_clock_id")] pub fn process_next_clock_id(&self) -> Option { unsafe { from_glib_full(ffi::gst_test_clock_process_next_clock_id( @@ -57,6 +62,7 @@ impl TestClock { } } + #[doc(alias = "gst_test_clock_wait_for_multiple_pending_ids")] pub fn wait_for_multiple_pending_ids(&self, count: u32) -> Vec { unsafe { let mut pending_list = ptr::null_mut(); @@ -69,6 +75,7 @@ impl TestClock { } } + #[doc(alias = "gst_test_clock_wait_for_next_pending_id")] pub fn wait_for_next_pending_id(&self) -> gst::ClockId { unsafe { let mut id = ptr::null_mut(); @@ -79,6 +86,7 @@ impl TestClock { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_test_clock_timed_wait_for_multiple_pending_ids")] pub fn timed_wait_for_multiple_pending_ids( &self, count: u32, diff --git a/gstreamer-editing-services/src/lib.rs b/gstreamer-editing-services/src/lib.rs index 212fc0f71..800d8f5d0 100644 --- a/gstreamer-editing-services/src/lib.rs +++ b/gstreamer-editing-services/src/lib.rs @@ -15,6 +15,7 @@ use glib::translate::from_glib; static GES_INIT: Once = Once::new(); +#[doc(alias = "ges_init")] pub fn init() -> Result<(), glib::BoolError> { if gst::init().is_err() { return Err(glib::bool_error!("Could not initialize GStreamer.")); diff --git a/gstreamer-editing-services/src/timeline_element.rs b/gstreamer-editing-services/src/timeline_element.rs index b80a6a584..a1293fafd 100644 --- a/gstreamer-editing-services/src/timeline_element.rs +++ b/gstreamer-editing-services/src/timeline_element.rs @@ -7,7 +7,9 @@ use std::ptr; pub trait TimelineElementExtManual: 'static { #[doc(alias = "get_child_property")] + #[doc(alias = "ges_timeline_element_get_child_property")] fn child_property(&self, name: &str) -> Option; + #[doc(alias = "ges_timeline_element_set_child_property")] fn set_child_property( &self, name: &str, diff --git a/gstreamer-gl/src/context.rs b/gstreamer-gl/src/context.rs index 3981d17fa..1226dcecb 100644 --- a/gstreamer-gl/src/context.rs +++ b/gstreamer-gl/src/context.rs @@ -8,7 +8,9 @@ use std::ptr; pub trait ContextGLExt { #[doc(alias = "get_gl_display")] + #[doc(alias = "gst_context_get_gl_display")] fn gl_display(&self) -> Option; + #[doc(alias = "gst_context_set_gl_display")] fn set_gl_display>(&self, display: &T); } diff --git a/gstreamer-gl/src/gl_context.rs b/gstreamer-gl/src/gl_context.rs index 73b972c1d..f3e0ba6bf 100644 --- a/gstreamer-gl/src/gl_context.rs +++ b/gstreamer-gl/src/gl_context.rs @@ -24,12 +24,14 @@ impl GLContext { } #[doc(alias = "get_current_gl_context")] + #[doc(alias = "gst_gl_context_get_current_gl_context")] pub fn current_gl_context(context_type: GLPlatform) -> uintptr_t { skip_assert_initialized!(); unsafe { ffi::gst_gl_context_get_current_gl_context(context_type.into_glib()) as uintptr_t } } #[doc(alias = "get_proc_address_with_platform")] + #[doc(alias = "gst_gl_context_get_proc_address_with_platform")] pub fn proc_address_with_platform( context_type: GLPlatform, gl_api: GLAPI, @@ -48,9 +50,11 @@ impl GLContext { pub trait GLContextExtManual: 'static { #[doc(alias = "get_gl_context")] + #[doc(alias = "gst_gl_context_get_gl_context")] fn gl_context(&self) -> uintptr_t; #[doc(alias = "get_proc_address")] + #[doc(alias = "gst_gl_context_get_proc_address")] fn proc_address(&self, name: &str) -> uintptr_t; } diff --git a/gstreamer-gl/src/gl_sync_meta.rs b/gstreamer-gl/src/gl_sync_meta.rs index 4c546e547..c76402f11 100644 --- a/gstreamer-gl/src/gl_sync_meta.rs +++ b/gstreamer-gl/src/gl_sync_meta.rs @@ -14,6 +14,7 @@ unsafe impl Send for GLSyncMeta {} unsafe impl Sync for GLSyncMeta {} impl GLSyncMeta { + #[doc(alias = "gst_buffer_add_gl_sync_meta")] pub fn add<'a, C: IsA>( buffer: &'a mut gst::BufferRef, context: &C, @@ -33,6 +34,7 @@ impl GLSyncMeta { unsafe { from_glib_none(self.0.context) } } + #[doc(alias = "gst_gl_sync_meta_set_sync_point")] pub fn set_sync_point>(&self, context: &C) { unsafe { ffi::gst_gl_sync_meta_set_sync_point( @@ -42,6 +44,7 @@ impl GLSyncMeta { } } + #[doc(alias = "gst_gl_sync_meta_wait")] pub fn wait>(&self, context: &C) { unsafe { ffi::gst_gl_sync_meta_wait( @@ -51,6 +54,7 @@ impl GLSyncMeta { } } + #[doc(alias = "gst_gl_sync_meta_wait_cpu")] pub fn wait_cpu>(&self, context: &C) { unsafe { ffi::gst_gl_sync_meta_wait_cpu( @@ -64,6 +68,7 @@ impl GLSyncMeta { unsafe impl MetaAPI for GLSyncMeta { type GstType = ffi::GstGLSyncMeta; + #[doc(alias = "gst_gl_sync_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_gl_sync_meta_api_get_type()) } } diff --git a/gstreamer-net/src/net_address_meta.rs b/gstreamer-net/src/net_address_meta.rs index d262b6901..8cd54d617 100644 --- a/gstreamer-net/src/net_address_meta.rs +++ b/gstreamer-net/src/net_address_meta.rs @@ -12,6 +12,7 @@ unsafe impl Send for NetAddressMeta {} unsafe impl Sync for NetAddressMeta {} impl NetAddressMeta { + #[doc(alias = "gst_buffer_add_net_address_meta")] pub fn add<'a, A: IsA>( buffer: &'a mut gst::BufferRef, addr: &A, @@ -43,6 +44,7 @@ impl NetAddressMeta { unsafe impl MetaAPI for NetAddressMeta { type GstType = ffi::GstNetAddressMeta; + #[doc(alias = "gst_net_address_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_net_address_meta_api_get_type()) } } diff --git a/gstreamer-net/src/net_client_clock.rs b/gstreamer-net/src/net_client_clock.rs index 1407cd0ce..4ce6bb44b 100644 --- a/gstreamer-net/src/net_client_clock.rs +++ b/gstreamer-net/src/net_client_clock.rs @@ -6,6 +6,7 @@ use glib::prelude::*; use glib::translate::*; impl NetClientClock { + #[doc(alias = "gst_net_client_clock_new")] pub fn new( name: Option<&str>, remote_address: &str, diff --git a/gstreamer-net/src/net_time_provider.rs b/gstreamer-net/src/net_time_provider.rs index 8035b11ad..ed280e830 100644 --- a/gstreamer-net/src/net_time_provider.rs +++ b/gstreamer-net/src/net_time_provider.rs @@ -6,6 +6,7 @@ use glib::prelude::*; use glib::translate::*; impl NetTimeProvider { + #[doc(alias = "gst_net_time_provider_new")] pub fn new>(clock: &P, address: Option<&str>, port: i32) -> NetTimeProvider { assert_initialized_main_thread!(); let address = address.to_glib_none(); diff --git a/gstreamer-net/src/ntp_clock.rs b/gstreamer-net/src/ntp_clock.rs index 58ca6911f..49a8a4454 100644 --- a/gstreamer-net/src/ntp_clock.rs +++ b/gstreamer-net/src/ntp_clock.rs @@ -6,6 +6,7 @@ use glib::prelude::*; use glib::translate::*; impl NtpClock { + #[doc(alias = "gst_ntp_clock_new")] pub fn new( name: Option<&str>, remote_address: &str, diff --git a/gstreamer-net/src/ptp_clock.rs b/gstreamer-net/src/ptp_clock.rs index 85a800960..6dc669ddc 100644 --- a/gstreamer-net/src/ptp_clock.rs +++ b/gstreamer-net/src/ptp_clock.rs @@ -6,6 +6,7 @@ use glib::prelude::*; use glib::translate::*; impl PtpClock { + #[doc(alias = "gst_ptp_clock_new")] pub fn new(name: Option<&str>, domain: u32) -> PtpClock { assert_initialized_main_thread!(); let name = name.to_glib_none(); diff --git a/gstreamer-pbutils/src/discoverer_video_info.rs b/gstreamer-pbutils/src/discoverer_video_info.rs index efee414b4..5b03e3292 100644 --- a/gstreamer-pbutils/src/discoverer_video_info.rs +++ b/gstreamer-pbutils/src/discoverer_video_info.rs @@ -6,6 +6,8 @@ use glib::translate::*; impl DiscovererVideoInfo { #[doc(alias = "get_framerate")] + #[doc(alias = "gst_discoverer_video_info_get_framerate_num")] + #[doc(alias = "gst_discoverer_video_info_get_framerate_denom")] pub fn framerate(&self) -> gst::Fraction { unsafe { gst::Fraction::new( @@ -16,6 +18,8 @@ impl DiscovererVideoInfo { } #[doc(alias = "get_par")] + #[doc(alias = "gst_discoverer_video_info_get_par_num")] + #[doc(alias = "gst_discoverer_video_info_get_par_denom")] pub fn par(&self) -> gst::Fraction { unsafe { gst::Fraction::new( diff --git a/gstreamer-pbutils/src/encoding_profile.rs b/gstreamer-pbutils/src/encoding_profile.rs index 6f7596ee0..55eb6ed13 100644 --- a/gstreamer-pbutils/src/encoding_profile.rs +++ b/gstreamer-pbutils/src/encoding_profile.rs @@ -29,6 +29,7 @@ trait EncodingProfileBuilderCommon { } impl> EncodingProfileBuilderCommon for O { + #[doc(alias = "gst_encoding_profile_set_allow_dynamic_output")] fn set_allow_dynamic_output(&self, allow_dynamic_output: bool) { unsafe { ffi::gst_encoding_profile_set_allow_dynamic_output( @@ -38,6 +39,7 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_description")] fn set_description(&self, description: Option<&str>) { let description = description.to_glib_none(); unsafe { @@ -48,6 +50,7 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_enabled")] fn set_enabled(&self, enabled: bool) { unsafe { ffi::gst_encoding_profile_set_enabled( @@ -57,6 +60,7 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_format")] fn set_format(&self, format: &gst::Caps) { unsafe { ffi::gst_encoding_profile_set_format( @@ -66,6 +70,7 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_name")] fn set_name(&self, name: Option<&str>) { let name = name.to_glib_none(); unsafe { @@ -73,12 +78,14 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_presence")] fn set_presence(&self, presence: u32) { unsafe { ffi::gst_encoding_profile_set_presence(self.as_ref().to_glib_none().0, presence); } } + #[doc(alias = "gst_encoding_profile_set_preset")] fn set_preset(&self, preset: Option<&str>) { let preset = preset.to_glib_none(); unsafe { @@ -86,6 +93,7 @@ impl> EncodingProfileBuilderCommon for O { } } + #[doc(alias = "gst_encoding_profile_set_preset_name")] fn set_preset_name(&self, preset_name: Option<&str>) { let preset_name = preset_name.to_glib_none(); unsafe { @@ -110,6 +118,7 @@ pub trait EncodingProfileHasRestrictionGetter { macro_rules! declare_encoding_profile_has_restriction( ($name:ident) => { impl EncodingProfileHasRestrictionSetter for $name { + #[doc(alias = "gst_encoding_profile_set_restriction")] fn set_restriction(&self, restriction: Option<&gst::Caps>) { let profile: &EncodingProfile = glib::object::Cast::upcast_ref(self); @@ -128,6 +137,7 @@ macro_rules! declare_encoding_profile_has_restriction( } impl EncodingProfileHasRestrictionGetter for $name { + #[doc(alias = "gst_encoding_profile_get_restriction")] fn restriction(&self) -> Option { let profile: &EncodingProfile = glib::object::Cast::upcast_ref(self); @@ -142,6 +152,7 @@ macro_rules! declare_encoding_profile_has_restriction( ); impl EncodingAudioProfile { + #[doc(alias = "gst_encoding_audio_profile_new")] fn new( format: &gst::Caps, preset: Option<&str>, @@ -165,6 +176,7 @@ impl EncodingAudioProfile { declare_encoding_profile_has_restriction!(EncodingAudioProfile); impl EncodingVideoProfile { + #[doc(alias = "gst_encoding_video_profile_new")] fn new( format: &gst::Caps, preset: Option<&str>, @@ -184,12 +196,14 @@ impl EncodingVideoProfile { } } + #[doc(alias = "gst_encoding_video_profile_set_pass")] fn set_pass(&self, pass: u32) { unsafe { ffi::gst_encoding_video_profile_set_pass(self.to_glib_none().0, pass); } } + #[doc(alias = "gst_encoding_video_profile_set_variableframerate")] fn set_variableframerate(&self, variableframerate: bool) { unsafe { ffi::gst_encoding_video_profile_set_variableframerate( @@ -203,6 +217,7 @@ impl EncodingVideoProfile { declare_encoding_profile_has_restriction!(EncodingVideoProfile); impl EncodingContainerProfile { + #[doc(alias = "gst_encoding_container_profile_new")] fn new( name: Option<&str>, description: Option<&str>, @@ -223,6 +238,7 @@ impl EncodingContainerProfile { } } + #[doc(alias = "gst_encoding_container_profile_add_profile")] fn add_profile>( &self, profile: &P, diff --git a/gstreamer-pbutils/src/functions.rs b/gstreamer-pbutils/src/functions.rs index b9ea8d94b..26a21849b 100644 --- a/gstreamer-pbutils/src/functions.rs +++ b/gstreamer-pbutils/src/functions.rs @@ -29,6 +29,7 @@ pub fn pb_utils_add_codec_description_to_tag_list_for_tag<'a, T: CodecTag<'a>>( } } +#[doc(alias = "gst_pb_utils_add_codec_description_to_tag_list")] pub fn pb_utils_add_codec_description_to_tag_list( taglist: &mut gst::TagListRef, caps: &gst::CapsRef, @@ -46,6 +47,7 @@ pub fn pb_utils_add_codec_description_to_tag_list( } } +#[doc(alias = "gst_pb_utils_get_encoder_description")] pub fn pb_utils_get_encoder_description( caps: &gst::CapsRef, ) -> Result { @@ -58,6 +60,7 @@ pub fn pb_utils_get_encoder_description( } } +#[doc(alias = "gst_pb_utils_get_decoder_description")] pub fn pb_utils_get_decoder_description( caps: &gst::CapsRef, ) -> Result { @@ -70,6 +73,7 @@ pub fn pb_utils_get_decoder_description( } } +#[doc(alias = "gst_pb_utils_get_codec_description")] pub fn pb_utils_get_codec_description( caps: &gst::CapsRef, ) -> Result { diff --git a/gstreamer-player/src/config.rs b/gstreamer-player/src/config.rs index f2327cb9b..22fea7544 100644 --- a/gstreamer-player/src/config.rs +++ b/gstreamer-player/src/config.rs @@ -36,6 +36,7 @@ impl AsMut for PlayerConfig { impl PlayerConfig { #[doc(alias = "get_position_update_interval")] + #[doc(alias = "gst_player_config_get_position_update_interval")] pub fn position_update_interval(&self) -> u32 { assert_initialized_main_thread!(); unsafe { ffi::gst_player_config_get_position_update_interval(self.0.to_glib_none().0) } @@ -52,6 +53,7 @@ impl PlayerConfig { } #[doc(alias = "get_user_agent")] + #[doc(alias = "gst_player_config_get_user_agent")] pub fn user_agent(&self) -> Option { assert_initialized_main_thread!(); unsafe { @@ -61,6 +63,7 @@ impl PlayerConfig { } } + #[doc(alias = "gst_player_config_set_position_update_interval")] pub fn set_position_update_interval(&mut self, interval: u32) { assert_initialized_main_thread!(); unsafe { @@ -78,6 +81,7 @@ impl PlayerConfig { self.set("accurate-seek", &accurate); } + #[doc(alias = "gst_player_config_set_user_agent")] pub fn set_user_agent(&mut self, agent: &str) { assert_initialized_main_thread!(); unsafe { diff --git a/gstreamer-player/src/player.rs b/gstreamer-player/src/player.rs index 557a99beb..8c52d6db3 100644 --- a/gstreamer-player/src/player.rs +++ b/gstreamer-player/src/player.rs @@ -11,6 +11,7 @@ use std::boxed::Box as Box_; use std::mem::transmute; impl Player { + #[doc(alias = "gst_player_new")] pub fn new( video_renderer: Option<&PlayerVideoRenderer>, signal_dispatcher: Option<&PlayerSignalDispatcher>, @@ -30,10 +31,12 @@ impl Player { } #[doc(alias = "get_config")] + #[doc(alias = "gst_player_get_config")] pub fn config(&self) -> crate::PlayerConfig { unsafe { from_glib_full(ffi::gst_player_get_config(self.to_glib_none().0)) } } + #[doc(alias = "gst_player_set_config")] pub fn set_config(&self, config: crate::PlayerConfig) -> Result<(), glib::error::BoolError> { unsafe { glib::result_from_gboolean!( diff --git a/gstreamer-player/src/player_g_main_context_signal_dispatcher.rs b/gstreamer-player/src/player_g_main_context_signal_dispatcher.rs index 1b12bee94..da1764ff9 100644 --- a/gstreamer-player/src/player_g_main_context_signal_dispatcher.rs +++ b/gstreamer-player/src/player_g_main_context_signal_dispatcher.rs @@ -4,6 +4,7 @@ use crate::PlayerGMainContextSignalDispatcher; use glib::translate::*; impl PlayerGMainContextSignalDispatcher { + #[doc(alias = "gst_player_g_main_context_signal_dispatcher_new")] pub fn new( application_context: Option<&glib::MainContext>, ) -> PlayerGMainContextSignalDispatcher { diff --git a/gstreamer-player/src/player_video_info.rs b/gstreamer-player/src/player_video_info.rs index 64a3e6caf..f6b501ef5 100644 --- a/gstreamer-player/src/player_video_info.rs +++ b/gstreamer-player/src/player_video_info.rs @@ -6,6 +6,7 @@ use std::mem; impl PlayerVideoInfo { #[doc(alias = "get_framerate")] + #[doc(alias = "gst_player_video_info_get_framerate")] pub fn framerate(&self) -> gst::Fraction { unsafe { let mut fps_n = mem::MaybeUninit::uninit(); @@ -20,6 +21,7 @@ impl PlayerVideoInfo { } #[doc(alias = "get_pixel_aspect_ratio")] + #[doc(alias = "gst_player_video_info_get_pixel_aspect_ratio")] pub fn pixel_aspect_ratio(&self) -> gst::Fraction { unsafe { let mut par_n = mem::MaybeUninit::uninit(); diff --git a/gstreamer-player/src/player_video_overlay_video_renderer.rs b/gstreamer-player/src/player_video_overlay_video_renderer.rs index 68159d571..f6727195f 100644 --- a/gstreamer-player/src/player_video_overlay_video_renderer.rs +++ b/gstreamer-player/src/player_video_overlay_video_renderer.rs @@ -29,6 +29,7 @@ impl PlayerVideoOverlayVideoRenderer { ) as *mut _) } + #[doc(alias = "gst_player_video_overlay_video_renderer_new_with_sink")] pub fn with_sink>(video_sink: &P) -> PlayerVideoOverlayVideoRenderer { assert_initialized_main_thread!(); diff --git a/gstreamer-rtp/src/rtp_buffer.rs b/gstreamer-rtp/src/rtp_buffer.rs index 0cbabf77a..8fd647fcf 100644 --- a/gstreamer-rtp/src/rtp_buffer.rs +++ b/gstreamer-rtp/src/rtp_buffer.rs @@ -80,42 +80,50 @@ impl<'a> RTPBuffer<'a, Writable> { } } + #[doc(alias = "gst_rtp_buffer_set_seq")] pub fn set_seq(&mut self, seq: u16) { unsafe { ffi::gst_rtp_buffer_set_seq(&mut self.rtp_buffer, seq); } } + #[doc(alias = "gst_rtp_buffer_set_marker")] pub fn set_marker(&mut self, m: bool) { unsafe { ffi::gst_rtp_buffer_set_marker(&mut self.rtp_buffer, m.into_glib()); } } + #[doc(alias = "gst_rtp_buffer_set_payload_type")] pub fn set_payload_type(&mut self, pt: u8) { unsafe { ffi::gst_rtp_buffer_set_payload_type(&mut self.rtp_buffer, pt); } } + #[doc(alias = "gst_rtp_buffer_set_ssrc")] pub fn set_ssrc(&mut self, ssrc: u32) { unsafe { ffi::gst_rtp_buffer_set_ssrc(&mut self.rtp_buffer, ssrc) } } + #[doc(alias = "gst_rtp_buffer_set_csrc")] pub fn set_csrc(&mut self, idx: u8, ssrc: u32) { unsafe { ffi::gst_rtp_buffer_set_csrc(&mut self.rtp_buffer, idx, ssrc) } } + #[doc(alias = "gst_rtp_buffer_set_timestamp")] pub fn set_timestamp(&mut self, rtptime: u32) { unsafe { ffi::gst_rtp_buffer_set_timestamp(&mut self.rtp_buffer, rtptime); } } + #[doc(alias = "gst_rtp_buffer_set_extension")] pub fn set_extension(&mut self, extension: bool) { unsafe { ffi::gst_rtp_buffer_set_extension(&mut self.rtp_buffer, extension.into_glib()) } } + #[doc(alias = "gst_rtp_buffer_add_extension_onebyte_header")] pub fn add_extension_onebyte_header( &mut self, id: u8, @@ -144,6 +152,7 @@ impl<'a> RTPBuffer<'a, Writable> { } } + #[doc(alias = "gst_rtp_buffer_add_extension_twobytes_header")] pub fn add_extension_twobytes_header( &mut self, appbits: u8, @@ -175,11 +184,13 @@ impl<'a> RTPBuffer<'a, Writable> { impl<'a, T> RTPBuffer<'a, T> { #[doc(alias = "get_seq")] + #[doc(alias = "gst_rtp_buffer_get_seq")] pub fn seq(&self) -> u16 { unsafe { ffi::gst_rtp_buffer_get_seq(glib::translate::mut_override(&self.rtp_buffer)) } } #[doc(alias = "get_payload_type")] + #[doc(alias = "gst_rtp_buffer_get_payload_type")] pub fn payload_type(&self) -> u8 { unsafe { ffi::gst_rtp_buffer_get_payload_type(glib::translate::mut_override(&self.rtp_buffer)) @@ -187,11 +198,13 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_ssrc")] + #[doc(alias = "gst_rtp_buffer_get_ssrc")] pub fn ssrc(&self) -> u32 { unsafe { ffi::gst_rtp_buffer_get_ssrc(glib::translate::mut_override(&self.rtp_buffer)) } } #[doc(alias = "get_timestamp")] + #[doc(alias = "gst_rtp_buffer_get_timestamp")] pub fn timestamp(&self) -> u32 { unsafe { ffi::gst_rtp_buffer_get_timestamp(glib::translate::mut_override(&self.rtp_buffer)) @@ -199,6 +212,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_csrc")] + #[doc(alias = "gst_rtp_buffer_get_csrc")] pub fn csrc(&self, idx: u8) -> Option { if idx < self.csrc_count() { unsafe { @@ -213,6 +227,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_csrc_count")] + #[doc(alias = "gst_rtp_buffer_get_csrc_count")] pub fn csrc_count(&self) -> u8 { unsafe { ffi::gst_rtp_buffer_get_csrc_count(glib::translate::mut_override(&self.rtp_buffer)) @@ -237,6 +252,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_payload")] + #[doc(alias = "gst_rtp_buffer_get_payload")] pub fn payload(&self) -> Result<&[u8], glib::error::BoolError> { let size = self.payload_size(); if size == 0 { @@ -263,6 +279,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_extension_bytes")] + #[doc(alias = "gst_rtp_buffer_get_extension_bytes")] pub fn extension_bytes(&self) -> Option<(u16, glib::Bytes)> { unsafe { let mut bits: u16 = 0; @@ -275,6 +292,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_extension_onebyte_header")] + #[doc(alias = "gst_rtp_buffer_get_extension_onebyte_header")] pub fn extension_onebyte_header(&self, id: u8, nth: u32) -> Option<&[u8]> { unsafe { let mut data = ptr::null_mut(); @@ -297,6 +315,7 @@ impl<'a, T> RTPBuffer<'a, T> { } #[doc(alias = "get_extension_twobytes_header")] + #[doc(alias = "gst_rtp_buffer_get_extension_twobytes_header")] pub fn extension_twobytes_header(&self, id: u8, nth: u32) -> Option<(u8, &[u8])> { unsafe { let mut data = ptr::null_mut(); @@ -358,6 +377,7 @@ impl RTPBufferExt for gst::Buffer { } } +#[doc(alias = "gst_rtp_buffer_compare_seqnum")] pub fn compare_seqnum(seqnum1: u16, seqnum2: u16) -> i32 { skip_assert_initialized!(); unsafe { ffi::gst_rtp_buffer_compare_seqnum(seqnum1, seqnum2) } diff --git a/gstreamer-rtsp-server/src/rtsp_address_pool.rs b/gstreamer-rtsp-server/src/rtsp_address_pool.rs index 59dbc1fb7..18ac1d070 100644 --- a/gstreamer-rtsp-server/src/rtsp_address_pool.rs +++ b/gstreamer-rtsp-server/src/rtsp_address_pool.rs @@ -8,6 +8,7 @@ use glib::translate::*; use std::ptr; pub trait RTSPAddressPoolExtManual: 'static { + #[doc(alias = "gst_rtsp_address_pool_reserve_address")] fn reserve_address( &self, ip_address: &str, diff --git a/gstreamer-rtsp-server/src/rtsp_auth.rs b/gstreamer-rtsp-server/src/rtsp_auth.rs index b8c724a95..9185e52ca 100644 --- a/gstreamer-rtsp-server/src/rtsp_auth.rs +++ b/gstreamer-rtsp-server/src/rtsp_auth.rs @@ -12,6 +12,7 @@ use crate::RTSPAuth; use crate::RTSPToken; pub trait RTSPAuthExtManual: 'static { + #[doc(alias = "gst_rtsp_auth_set_default_token")] fn set_default_token(&self, token: Option<&mut RTSPToken>); fn connect_accept_certificate< diff --git a/gstreamer-rtsp-server/src/rtsp_client.rs b/gstreamer-rtsp-server/src/rtsp_client.rs index ec0f3466a..ba6f74cae 100644 --- a/gstreamer-rtsp-server/src/rtsp_client.rs +++ b/gstreamer-rtsp-server/src/rtsp_client.rs @@ -6,6 +6,7 @@ use glib::source::SourceId; use glib::translate::*; pub trait RTSPClientExtManual: 'static { + #[doc(alias = "gst_rtsp_client_attach")] fn attach(&self, context: Option<&glib::MainContext>) -> SourceId; } diff --git a/gstreamer-rtsp-server/src/rtsp_media.rs b/gstreamer-rtsp-server/src/rtsp_media.rs index 69dd2b67f..4a74972b4 100644 --- a/gstreamer-rtsp-server/src/rtsp_media.rs +++ b/gstreamer-rtsp-server/src/rtsp_media.rs @@ -6,6 +6,7 @@ use glib::translate::*; use crate::RTSPMedia; pub trait RTSPMediaExtManual: 'static { + #[doc(alias = "gst_rtsp_media_take_pipeline")] fn take_pipeline>(&self, pipeline: &P); } diff --git a/gstreamer-rtsp-server/src/rtsp_media_factory.rs b/gstreamer-rtsp-server/src/rtsp_media_factory.rs index b423c7585..cd264c09d 100644 --- a/gstreamer-rtsp-server/src/rtsp_media_factory.rs +++ b/gstreamer-rtsp-server/src/rtsp_media_factory.rs @@ -10,6 +10,7 @@ use glib::translate::*; pub trait RTSPMediaFactoryExtManual: 'static { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_rtsp_media_factory_add_role_from_structure")] fn add_role_from_structure(&self, structure: &gst::StructureRef); } diff --git a/gstreamer-rtsp-server/src/rtsp_server.rs b/gstreamer-rtsp-server/src/rtsp_server.rs index 4ee8bac05..9ba9ee80b 100644 --- a/gstreamer-rtsp-server/src/rtsp_server.rs +++ b/gstreamer-rtsp-server/src/rtsp_server.rs @@ -6,6 +6,7 @@ use glib::source::SourceId; use glib::translate::*; pub trait RTSPServerExtManual: 'static { + #[doc(alias = "gst_rtsp_server_attach")] fn attach( &self, context: Option<&glib::MainContext>, diff --git a/gstreamer-rtsp-server/src/rtsp_session_pool.rs b/gstreamer-rtsp-server/src/rtsp_session_pool.rs index fd47292fa..8e2a6783f 100644 --- a/gstreamer-rtsp-server/src/rtsp_session_pool.rs +++ b/gstreamer-rtsp-server/src/rtsp_session_pool.rs @@ -31,6 +31,7 @@ fn into_raw_watch Continue + Send + 'static>(func: } pub trait RTSPSessionPoolExtManual: 'static { + #[doc(alias = "gst_rtsp_session_pool_create_watch")] fn create_watch(&self, name: Option<&str>, priority: Priority, func: F) -> glib::Source where F: FnMut(&RTSPSessionPool) -> Continue + Send + 'static; diff --git a/gstreamer-rtsp-server/src/rtsp_thread.rs b/gstreamer-rtsp-server/src/rtsp_thread.rs index 66f05030f..a76d1de77 100644 --- a/gstreamer-rtsp-server/src/rtsp_thread.rs +++ b/gstreamer-rtsp-server/src/rtsp_thread.rs @@ -7,6 +7,7 @@ gst::mini_object_wrapper!(RTSPThread, RTSPThreadRef, ffi::GstRTSPThread, || { }); impl RTSPThread { + #[doc(alias = "gst_rtsp_thread_new")] pub fn new(type_: crate::RTSPThreadType) -> Option { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_rtsp_thread_new(type_.into_glib())) } @@ -14,10 +15,12 @@ impl RTSPThread { } impl RTSPThreadRef { + #[doc(alias = "gst_rtsp_thread_reuse")] pub fn reuse(&self) -> bool { unsafe { from_glib(ffi::gst_rtsp_thread_reuse(self.as_mut_ptr())) } } + #[doc(alias = "gst_rtsp_thread_stop")] pub fn stop(&self) { unsafe { ffi::gst_rtsp_thread_stop(self.as_mut_ptr()); diff --git a/gstreamer-rtsp-server/src/rtsp_token.rs b/gstreamer-rtsp-server/src/rtsp_token.rs index 4ec5ebb7f..d0d1a98d2 100644 --- a/gstreamer-rtsp-server/src/rtsp_token.rs +++ b/gstreamer-rtsp-server/src/rtsp_token.rs @@ -10,6 +10,7 @@ gst::mini_object_wrapper!(RTSPToken, RTSPTokenRef, ffi::GstRTSPToken, || { }); impl RTSPToken { + #[doc(alias = "gst_rtsp_token_new_empty")] pub fn new_empty() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_rtsp_token_new_empty()) } @@ -34,6 +35,7 @@ impl RTSPToken { impl RTSPTokenRef { #[doc(alias = "get_string")] + #[doc(alias = "gst_rtsp_token_get_string")] pub fn string(&self, field: &str) -> Option { unsafe { from_glib_none(ffi::gst_rtsp_token_get_string( @@ -44,10 +46,12 @@ impl RTSPTokenRef { } #[doc(alias = "get_structure")] + #[doc(alias = "gst_rtsp_token_get_structure")] pub fn structure(&self) -> Option { unsafe { from_glib_none(ffi::gst_rtsp_token_get_structure(self.as_mut_ptr())) } } + #[doc(alias = "gst_rtsp_token_is_allowed")] pub fn is_allowed(&self, field: &str) -> bool { unsafe { from_glib(ffi::gst_rtsp_token_is_allowed( diff --git a/gstreamer-sdp/src/sdp_media.rs b/gstreamer-sdp/src/sdp_media.rs index 2b35a83ab..62dfec383 100644 --- a/gstreamer-sdp/src/sdp_media.rs +++ b/gstreamer-sdp/src/sdp_media.rs @@ -31,6 +31,7 @@ glib::wrapper! { } impl SDPMedia { + #[doc(alias = "gst_sdp_media_new")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { @@ -121,17 +122,20 @@ unsafe impl Send for SDPMediaRef {} unsafe impl Sync for SDPMediaRef {} impl SDPMediaRef { + #[doc(alias = "gst_sdp_media_add_attribute")] pub fn add_attribute(&mut self, key: &str, value: Option<&str>) { let value = value.to_glib_none(); unsafe { ffi::gst_sdp_media_add_attribute(&mut self.0, key.to_glib_none().0, value.0) }; } + #[doc(alias = "gst_sdp_media_add_bandwidth")] pub fn add_bandwidth(&mut self, bwtype: &str, bandwidth: u32) { unsafe { ffi::gst_sdp_media_add_bandwidth(&mut self.0, bwtype.to_glib_none().0, bandwidth) }; } + #[doc(alias = "gst_sdp_media_add_connection")] pub fn add_connection( &mut self, nettype: &str, @@ -152,10 +156,12 @@ impl SDPMediaRef { }; } + #[doc(alias = "gst_sdp_media_add_format")] pub fn add_format(&mut self, format: &str) { unsafe { ffi::gst_sdp_media_add_format(&mut self.0, format.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_media_as_text")] pub fn as_text(&self) -> Result { unsafe { match from_glib_full(ffi::gst_sdp_media_as_text(&self.0)) { @@ -183,10 +189,12 @@ impl SDPMediaRef { ConnectionsIter::new(self) } + #[doc(alias = "gst_sdp_media_attributes_len")] pub fn attributes_len(&self) -> u32 { unsafe { ffi::gst_sdp_media_attributes_len(&self.0) } } + #[doc(alias = "gst_sdp_media_attributes_to_caps")] pub fn attributes_to_caps(&self, caps: &mut gst::CapsRef) -> Result<(), glib::BoolError> { let result = unsafe { ffi::gst_sdp_media_attributes_to_caps(&self.0, caps.as_mut_ptr()) }; match result { @@ -195,19 +203,23 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_bandwidths_len")] pub fn bandwidths_len(&self) -> u32 { unsafe { ffi::gst_sdp_media_bandwidths_len(&self.0) } } + #[doc(alias = "gst_sdp_media_connections_len")] pub fn connections_len(&self) -> u32 { unsafe { ffi::gst_sdp_media_connections_len(&self.0) } } + #[doc(alias = "gst_sdp_media_formats_len")] pub fn formats_len(&self) -> u32 { unsafe { ffi::gst_sdp_media_formats_len(&self.0) } } #[doc(alias = "get_attribute")] + #[doc(alias = "gst_sdp_media_get_attribute")] pub fn attribute(&self, idx: u32) -> Option<&SDPAttribute> { if idx >= self.attributes_len() { return None; @@ -224,6 +236,7 @@ impl SDPMediaRef { } #[doc(alias = "get_attribute_val")] + #[doc(alias = "gst_sdp_media_get_attribute_val")] pub fn attribute_val(&self, key: &str) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_media_get_attribute_val(&self.0, key.to_glib_none().0); @@ -236,6 +249,7 @@ impl SDPMediaRef { } #[doc(alias = "get_attribute_val_n")] + #[doc(alias = "gst_sdp_media_get_attribute_val_n")] pub fn attribute_val_n(&self, key: &str, nth: u32) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_media_get_attribute_val_n(&self.0, key.to_glib_none().0, nth); @@ -248,6 +262,7 @@ impl SDPMediaRef { } #[doc(alias = "get_bandwidth")] + #[doc(alias = "gst_sdp_media_get_bandwidth")] pub fn bandwidth(&self, idx: u32) -> Option<&SDPBandwidth> { if idx >= self.bandwidths_len() { return None; @@ -264,11 +279,13 @@ impl SDPMediaRef { } #[doc(alias = "get_caps_from_media")] + #[doc(alias = "gst_sdp_media_get_caps_from_media")] pub fn caps_from_media(&self, pt: i32) -> Option { unsafe { from_glib_full(ffi::gst_sdp_media_get_caps_from_media(&self.0, pt)) } } #[doc(alias = "get_connection")] + #[doc(alias = "gst_sdp_media_get_connection")] pub fn connection(&self, idx: u32) -> Option<&SDPConnection> { if idx >= self.connections_len() { return None; @@ -285,6 +302,7 @@ impl SDPMediaRef { } #[doc(alias = "get_format")] + #[doc(alias = "gst_sdp_media_get_format")] pub fn format(&self, idx: u32) -> Option<&str> { if idx >= self.formats_len() { return None; @@ -301,6 +319,7 @@ impl SDPMediaRef { } #[doc(alias = "get_information")] + #[doc(alias = "gst_sdp_media_get_information")] pub fn information(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_media_get_information(&self.0); @@ -313,6 +332,7 @@ impl SDPMediaRef { } #[doc(alias = "get_key")] + #[doc(alias = "gst_sdp_media_get_key")] pub fn key(&self) -> Option<&SDPKey> { unsafe { let ptr = ffi::gst_sdp_media_get_key(&self.0); @@ -325,6 +345,7 @@ impl SDPMediaRef { } #[doc(alias = "get_media")] + #[doc(alias = "gst_sdp_media_get_media")] pub fn media(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_media_get_media(&self.0); @@ -337,16 +358,19 @@ impl SDPMediaRef { } #[doc(alias = "get_num_ports")] + #[doc(alias = "gst_sdp_media_get_num_ports")] pub fn num_ports(&self) -> u32 { unsafe { ffi::gst_sdp_media_get_num_ports(&self.0) } } #[doc(alias = "get_port")] + #[doc(alias = "gst_sdp_media_get_port")] pub fn port(&self) -> u32 { unsafe { ffi::gst_sdp_media_get_port(&self.0) } } #[doc(alias = "get_proto")] + #[doc(alias = "gst_sdp_media_get_proto")] pub fn proto(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_media_get_proto(&self.0); @@ -358,6 +382,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_insert_attribute")] pub fn insert_attribute( &mut self, idx: Option, @@ -378,6 +403,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_insert_bandwidth")] pub fn insert_bandwidth( &mut self, idx: Option, @@ -398,6 +424,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_insert_connection")] pub fn insert_connection( &mut self, idx: Option, @@ -418,6 +445,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_insert_format")] pub fn insert_format(&mut self, idx: Option, format: &str) -> Result<(), glib::BoolError> { if let Some(idx) = idx { if idx >= self.formats_len() { @@ -434,6 +462,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_remove_attribute")] pub fn remove_attribute(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.attributes_len() { return Err(glib::bool_error!("Failed to remove attribute")); @@ -446,6 +475,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_remove_bandwidth")] pub fn remove_bandwidth(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.bandwidths_len() { return Err(glib::bool_error!("Failed to remove bandwidth")); @@ -458,6 +488,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_remove_connection")] pub fn remove_connection(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.connections_len() { return Err(glib::bool_error!("Failed to remove connection")); @@ -470,6 +501,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_remove_format")] pub fn remove_format(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.formats_len() { return Err(glib::bool_error!("Failed to remove format")); @@ -482,6 +514,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_replace_attribute")] pub fn replace_attribute( &mut self, idx: u32, @@ -499,6 +532,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_replace_bandwidth")] pub fn replace_bandwidth(&mut self, idx: u32, bw: SDPBandwidth) -> Result<(), glib::BoolError> { if idx >= self.bandwidths_len() { return Err(glib::bool_error!("Failed to replace bandwidth")); @@ -512,6 +546,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_replace_connection")] pub fn replace_connection( &mut self, idx: u32, @@ -530,6 +565,7 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_replace_format")] pub fn replace_format(&mut self, idx: u32, format: &str) -> Result<(), glib::BoolError> { if idx >= self.formats_len() { return Err(glib::bool_error!("Failed to replace format")); @@ -543,28 +579,34 @@ impl SDPMediaRef { } } + #[doc(alias = "gst_sdp_media_set_information")] pub fn set_information(&mut self, information: &str) { unsafe { ffi::gst_sdp_media_set_information(&mut self.0, information.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_media_set_key")] pub fn set_key(&mut self, type_: &str, data: &str) { unsafe { ffi::gst_sdp_media_set_key(&mut self.0, type_.to_glib_none().0, data.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_media_set_media")] pub fn set_media(&mut self, med: &str) { unsafe { ffi::gst_sdp_media_set_media(&mut self.0, med.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_media_set_port_info")] pub fn set_port_info(&mut self, port: u32, num_ports: u32) { unsafe { ffi::gst_sdp_media_set_port_info(&mut self.0, port, num_ports) }; } + #[doc(alias = "gst_sdp_media_set_proto")] pub fn set_proto(&mut self, proto: &str) { unsafe { ffi::gst_sdp_media_set_proto(&mut self.0, proto.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_media_set_media_from_caps")] pub fn set_media_from_caps( caps: &gst::Caps, media: &mut SDPMedia, diff --git a/gstreamer-sdp/src/sdp_message.rs b/gstreamer-sdp/src/sdp_message.rs index 026c9999c..65b7d338d 100644 --- a/gstreamer-sdp/src/sdp_message.rs +++ b/gstreamer-sdp/src/sdp_message.rs @@ -71,6 +71,7 @@ impl fmt::Display for SDPMessage { } impl SDPMessage { + #[doc(alias = "gst_sdp_message_new")] pub fn new() -> SDPMessage { assert_initialized_main_thread!(); unsafe { @@ -80,6 +81,7 @@ impl SDPMessage { } } + #[doc(alias = "gst_sdp_message_parse_buffer")] pub fn parse_buffer(data: &[u8]) -> Result { assert_initialized_main_thread!(); unsafe { @@ -97,6 +99,7 @@ impl SDPMessage { } } + #[doc(alias = "gst_sdp_message_parse_uri")] pub fn parse_uri(uri: &str) -> Result { assert_initialized_main_thread!(); unsafe { @@ -163,6 +166,7 @@ unsafe impl Send for SDPMessageRef {} unsafe impl Sync for SDPMessageRef {} impl SDPMessageRef { + #[doc(alias = "gst_sdp_message_add_attribute")] pub fn add_attribute(&mut self, key: &str, value: Option<&str>) { unsafe { ffi::gst_sdp_message_add_attribute( @@ -173,10 +177,12 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_add_email")] pub fn add_email(&mut self, email: &str) { unsafe { ffi::gst_sdp_message_add_email(&mut self.0, email.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_add_media")] pub fn add_media(&mut self, media: SDPMedia) { unsafe { ffi::gst_sdp_message_add_media( @@ -186,10 +192,12 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_add_phone")] pub fn add_phone(&mut self, phone: &str) { unsafe { ffi::gst_sdp_message_add_phone(&mut self.0, phone.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_add_time")] pub fn add_time(&mut self, start: &str, stop: &str, repeat: &[&str]) { unsafe { ffi::gst_sdp_message_add_time( @@ -201,6 +209,7 @@ impl SDPMessageRef { }; } + #[doc(alias = "gst_sdp_message_add_zone")] pub fn add_zone(&mut self, adj_time: &str, typed_time: &str) { unsafe { ffi::gst_sdp_message_add_zone( @@ -211,6 +220,7 @@ impl SDPMessageRef { }; } + #[doc(alias = "gst_sdp_message_as_text")] pub fn as_text(&self) -> Result { unsafe { match from_glib_full(ffi::gst_sdp_message_as_text(&self.0)) { @@ -222,10 +232,12 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_attributes_len")] pub fn attributes_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_attributes_len(&self.0) } } + #[doc(alias = "gst_sdp_message_attributes_to_caps")] pub fn attributes_to_caps(&self, caps: &mut gst::CapsRef) -> Result<(), glib::BoolError> { let result = unsafe { ffi::gst_sdp_message_attributes_to_caps(&self.0, caps.as_mut_ptr()) }; match result { @@ -234,19 +246,23 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_bandwidths_len")] pub fn bandwidths_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_bandwidths_len(&self.0) } } + #[doc(alias = "gst_sdp_message_dump")] pub fn dump(&self) { unsafe { ffi::gst_sdp_message_dump(&self.0) }; } + #[doc(alias = "gst_sdp_message_emails_len")] pub fn emails_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_emails_len(&self.0) } } #[doc(alias = "get_attribute")] + #[doc(alias = "gst_sdp_message_get_attribute")] pub fn attribute(&self, idx: u32) -> Option<&SDPAttribute> { if idx >= self.attributes_len() { return None; @@ -263,6 +279,7 @@ impl SDPMessageRef { } #[doc(alias = "get_attribute_val")] + #[doc(alias = "gst_sdp_message_get_attribute_val")] pub fn attribute_val(&self, key: &str) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_attribute_val(&self.0, key.to_glib_none().0); @@ -275,6 +292,7 @@ impl SDPMessageRef { } #[doc(alias = "get_attribute_val_n")] + #[doc(alias = "gst_sdp_message_get_attribute_val_n")] pub fn attribute_val_n(&self, key: &str, nth: u32) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_attribute_val_n(&self.0, key.to_glib_none().0, nth); @@ -287,6 +305,7 @@ impl SDPMessageRef { } #[doc(alias = "get_bandwidth")] + #[doc(alias = "gst_sdp_message_get_bandwidth")] pub fn bandwidth(&self, idx: u32) -> Option<&SDPBandwidth> { if idx >= self.bandwidths_len() { return None; @@ -303,6 +322,7 @@ impl SDPMessageRef { } #[doc(alias = "get_connection")] + #[doc(alias = "gst_sdp_message_get_connection")] pub fn connection(&self) -> Option<&SDPConnection> { unsafe { let ptr = ffi::gst_sdp_message_get_connection(&self.0); @@ -315,6 +335,7 @@ impl SDPMessageRef { } #[doc(alias = "get_email")] + #[doc(alias = "gst_sdp_message_get_email")] pub fn email(&self, idx: u32) -> Option<&str> { if idx >= self.emails_len() { return None; @@ -331,6 +352,7 @@ impl SDPMessageRef { } #[doc(alias = "get_information")] + #[doc(alias = "gst_sdp_message_get_information")] pub fn information(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_information(&self.0); @@ -343,6 +365,7 @@ impl SDPMessageRef { } #[doc(alias = "get_key")] + #[doc(alias = "gst_sdp_message_get_key")] pub fn key(&self) -> Option<&SDPKey> { unsafe { let ptr = ffi::gst_sdp_message_get_key(&self.0); @@ -355,6 +378,7 @@ impl SDPMessageRef { } #[doc(alias = "get_media")] + #[doc(alias = "gst_sdp_message_get_media")] pub fn media(&self, idx: u32) -> Option<&SDPMediaRef> { if idx >= self.medias_len() { return None; @@ -387,6 +411,7 @@ impl SDPMessageRef { } #[doc(alias = "get_origin")] + #[doc(alias = "gst_sdp_message_get_origin")] pub fn origin(&self) -> Option<&SDPOrigin> { unsafe { let ptr = ffi::gst_sdp_message_get_origin(&self.0); @@ -399,6 +424,7 @@ impl SDPMessageRef { } #[doc(alias = "get_phone")] + #[doc(alias = "gst_sdp_message_get_phone")] pub fn phone(&self, idx: u32) -> Option<&str> { if idx >= self.phones_len() { return None; @@ -415,6 +441,7 @@ impl SDPMessageRef { } #[doc(alias = "get_session_name")] + #[doc(alias = "gst_sdp_message_get_session_name")] pub fn session_name(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_session_name(&self.0); @@ -427,6 +454,7 @@ impl SDPMessageRef { } #[doc(alias = "get_time")] + #[doc(alias = "gst_sdp_message_get_time")] pub fn time(&self, idx: u32) -> Option<&SDPTime> { if idx >= self.times_len() { return None; @@ -443,6 +471,7 @@ impl SDPMessageRef { } #[doc(alias = "get_uri")] + #[doc(alias = "gst_sdp_message_get_uri")] pub fn uri(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_uri(&self.0); @@ -455,6 +484,7 @@ impl SDPMessageRef { } #[doc(alias = "get_version")] + #[doc(alias = "gst_sdp_message_get_version")] pub fn version(&self) -> Option<&str> { unsafe { let ptr = ffi::gst_sdp_message_get_version(&self.0); @@ -467,6 +497,7 @@ impl SDPMessageRef { } #[doc(alias = "get_zone")] + #[doc(alias = "gst_sdp_message_get_zone")] pub fn zone(&self, idx: u32) -> Option<&SDPZone> { if idx >= self.zones_len() { return None; @@ -482,6 +513,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_attribute")] pub fn insert_attribute( &mut self, idx: Option, @@ -503,6 +535,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_bandwidth")] pub fn insert_bandwidth( &mut self, idx: Option, @@ -523,6 +556,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_email")] pub fn insert_email(&mut self, idx: Option, email: &str) -> Result<(), glib::BoolError> { if let Some(idx) = idx { if idx >= self.emails_len() { @@ -539,6 +573,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_phone")] pub fn insert_phone(&mut self, idx: Option, phone: &str) -> Result<(), glib::BoolError> { if let Some(idx) = idx { if idx >= self.phones_len() { @@ -555,6 +590,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_time")] pub fn insert_time(&mut self, idx: Option, time: SDPTime) -> Result<(), glib::BoolError> { if let Some(idx) = idx { if idx >= self.times_len() { @@ -571,6 +607,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_insert_zone")] pub fn insert_zone(&mut self, idx: Option, zone: SDPZone) -> Result<(), glib::BoolError> { if let Some(idx) = idx { if idx >= self.zones_len() { @@ -587,14 +624,17 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_medias_len")] pub fn medias_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_medias_len(&self.0) } } + #[doc(alias = "gst_sdp_message_phones_len")] pub fn phones_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_phones_len(&self.0) } } + #[doc(alias = "gst_sdp_message_remove_attribute")] pub fn remove_attribute(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.attributes_len() { return Err(glib::bool_error!("Failed to remove attribute")); @@ -607,6 +647,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_remove_bandwidth")] pub fn remove_bandwidth(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.bandwidths_len() { return Err(glib::bool_error!("Failed to remove bandwidth")); @@ -619,6 +660,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_remove_email")] pub fn remove_email(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.emails_len() { return Err(glib::bool_error!("Failed to remove email")); @@ -631,6 +673,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_remove_phone")] pub fn remove_phone(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.phones_len() { return Err(glib::bool_error!("Failed to remove phone")); @@ -643,6 +686,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_remove_time")] pub fn remove_time(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.times_len() { return Err(glib::bool_error!("Failed to remove time")); @@ -655,6 +699,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_remove_zone")] pub fn remove_zone(&mut self, idx: u32) -> Result<(), glib::BoolError> { if idx >= self.zones_len() { return Err(glib::bool_error!("Failed to remove zone")); @@ -667,6 +712,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_attribute")] pub fn replace_attribute( &mut self, idx: u32, @@ -685,6 +731,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_bandwidth")] pub fn replace_bandwidth(&mut self, idx: u32, bw: SDPBandwidth) -> Result<(), glib::BoolError> { if idx >= self.bandwidths_len() { return Err(glib::bool_error!("Failed to replace bandwidth")); @@ -698,6 +745,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_email")] pub fn replace_email(&mut self, idx: u32, email: &str) -> Result<(), glib::BoolError> { if idx >= self.emails_len() { return Err(glib::bool_error!("Failed to replace email")); @@ -711,6 +759,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_phone")] pub fn replace_phone(&mut self, idx: u32, phone: &str) -> Result<(), glib::BoolError> { if idx >= self.phones_len() { return Err(glib::bool_error!("Failed to replace phone")); @@ -724,6 +773,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_time")] pub fn replace_time(&mut self, idx: u32, time: SDPTime) -> Result<(), glib::BoolError> { if idx >= self.times_len() { return Err(glib::bool_error!("Failed to replace time")); @@ -737,6 +787,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_replace_zone")] pub fn replace_zone(&mut self, idx: u32, zone: SDPZone) -> Result<(), glib::BoolError> { if idx >= self.zones_len() { return Err(glib::bool_error!("Failed to replace zone")); @@ -750,6 +801,7 @@ impl SDPMessageRef { } } + #[doc(alias = "gst_sdp_message_set_connection")] pub fn set_connection( &mut self, nettype: &str, @@ -770,16 +822,19 @@ impl SDPMessageRef { }; } + #[doc(alias = "gst_sdp_message_set_information")] pub fn set_information(&mut self, information: &str) { unsafe { ffi::gst_sdp_message_set_information(&mut self.0, information.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_set_key")] pub fn set_key(&mut self, type_: &str, data: &str) { unsafe { ffi::gst_sdp_message_set_key(&mut self.0, type_.to_glib_none().0, data.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_set_origin")] pub fn set_origin( &mut self, username: &str, @@ -802,28 +857,34 @@ impl SDPMessageRef { }; } + #[doc(alias = "gst_sdp_message_set_session_name")] pub fn set_session_name(&mut self, session_name: &str) { unsafe { ffi::gst_sdp_message_set_session_name(&mut self.0, session_name.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_set_uri")] pub fn set_uri(&mut self, uri: &str) { unsafe { ffi::gst_sdp_message_set_uri(&mut self.0, uri.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_set_version")] pub fn set_version(&mut self, version: &str) { unsafe { ffi::gst_sdp_message_set_version(&mut self.0, version.to_glib_none().0) }; } + #[doc(alias = "gst_sdp_message_times_len")] pub fn times_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_times_len(&self.0) } } + #[doc(alias = "gst_sdp_message_zones_len")] pub fn zones_len(&self) -> u32 { unsafe { ffi::gst_sdp_message_zones_len(&self.0) } } + #[doc(alias = "gst_sdp_message_as_uri")] pub fn as_uri(&self, scheme: &str) -> Result { assert_initialized_main_thread!(); unsafe { diff --git a/gstreamer-video/src/functions.rs b/gstreamer-video/src/functions.rs index 7fd0ff4ff..f8cfce66a 100644 --- a/gstreamer-video/src/functions.rs +++ b/gstreamer-video/src/functions.rs @@ -7,6 +7,7 @@ use std::i32; use std::mem; use std::ptr; +#[doc(alias = "gst_video_convert_sample")] pub fn convert_sample( sample: &gst::Sample, caps: &gst::Caps, @@ -132,6 +133,7 @@ pub fn convert_sample_future( Box::pin(future) } +#[doc(alias = "gst_video_calculate_display_ratio")] pub fn calculate_display_ratio( video_width: u32, video_height: u32, @@ -165,6 +167,7 @@ pub fn calculate_display_ratio( } } +#[doc(alias = "gst_video_guess_framerate")] pub fn guess_framerate(duration: gst::ClockTime) -> Option { skip_assert_initialized!(); diff --git a/gstreamer-video/src/video_buffer_pool.rs b/gstreamer-video/src/video_buffer_pool.rs index 2274288cc..7a290913d 100644 --- a/gstreamer-video/src/video_buffer_pool.rs +++ b/gstreamer-video/src/video_buffer_pool.rs @@ -105,6 +105,7 @@ pub trait VideoBufferPoolConfig { } impl VideoBufferPoolConfig for gst::BufferPoolConfig { + #[doc(alias = "gst_buffer_pool_config_get_video_alignment")] fn video_alignment(&self) -> Option { unsafe { let mut alignment = mem::MaybeUninit::zeroed(); @@ -120,6 +121,7 @@ impl VideoBufferPoolConfig for gst::BufferPoolConfig { } } + #[doc(alias = "gst_buffer_pool_config_set_video_alignment")] fn set_video_alignment(&mut self, align: &VideoAlignment) { unsafe { ffi::gst_buffer_pool_config_set_video_alignment( diff --git a/gstreamer-video/src/video_converter.rs b/gstreamer-video/src/video_converter.rs index e3488dd98..5f55ab5ce 100644 --- a/gstreamer-video/src/video_converter.rs +++ b/gstreamer-video/src/video_converter.rs @@ -21,6 +21,7 @@ unsafe impl Send for VideoConverter {} unsafe impl Sync for VideoConverter {} impl VideoConverter { + #[doc(alias = "gst_video_converter_new")] pub fn new( in_info: &crate::VideoInfo, out_info: &crate::VideoInfo, @@ -50,6 +51,7 @@ impl VideoConverter { } #[doc(alias = "get_config")] + #[doc(alias = "gst_video_converter_get_config")] pub fn config(&self) -> VideoConverterConfig { unsafe { VideoConverterConfig( @@ -61,12 +63,14 @@ impl VideoConverter { } } + #[doc(alias = "gst_video_converter_set_config")] pub fn set_config(&mut self, config: VideoConverterConfig) { unsafe { ffi::gst_video_converter_set_config(self.0.as_ptr(), config.0.into_ptr()); } } + #[doc(alias = "gst_video_converter_frame")] pub fn frame( &self, src: &crate::VideoFrame, diff --git a/gstreamer-video/src/video_decoder.rs b/gstreamer-video/src/video_decoder.rs index 43e782c28..7276ef2ef 100644 --- a/gstreamer-video/src/video_decoder.rs +++ b/gstreamer-video/src/video_decoder.rs @@ -112,6 +112,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams) { unsafe { let mut allocator = ptr::null_mut(); @@ -125,6 +126,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_finish_frame")] fn finish_frame(&self, frame: VideoCodecFrame) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_video_decoder_finish_frame( @@ -134,12 +136,14 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_release_frame")] fn release_frame(&self, frame: VideoCodecFrame) { unsafe { ffi::gst_video_decoder_release_frame(self.as_ref().to_glib_none().0, frame.into_ptr()) } } + #[doc(alias = "gst_video_decoder_drop_frame")] fn drop_frame(&self, frame: VideoCodecFrame) -> Result { unsafe { gst::FlowSuccess::try_from_glib(ffi::gst_video_decoder_drop_frame( @@ -149,6 +153,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_latency")] fn latency(&self) -> (gst::ClockTime, gst::ClockTime) { let mut min_latency = gst::ffi::GST_CLOCK_TIME_NONE; let mut max_latency = gst::ffi::GST_CLOCK_TIME_NONE; @@ -164,6 +169,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_set_latency")] fn set_latency(&self, min_latency: gst::ClockTime, max_latency: gst::ClockTime) { unsafe { ffi::gst_video_decoder_set_latency( @@ -174,6 +180,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_frame")] fn frame(&self, frame_number: i32) -> Option { let frame = unsafe { ffi::gst_video_decoder_get_frame(self.as_ref().to_glib_none().0, frame_number) @@ -186,6 +193,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_frames")] fn frames(&self) -> Vec { unsafe { let frames = ffi::gst_video_decoder_get_frames(self.as_ref().to_glib_none().0); @@ -205,6 +213,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_oldest_frame")] fn oldest_frame(&self) -> Option { let frame = unsafe { ffi::gst_video_decoder_get_oldest_frame(self.as_ref().to_glib_none().0) }; @@ -216,6 +225,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_get_output_state")] fn output_state(&self) -> Option> { let state = unsafe { ffi::gst_video_decoder_get_output_state(self.as_ref().to_glib_none().0) }; @@ -227,6 +237,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_set_output_state")] fn set_output_state( &self, fmt: VideoFormat, @@ -257,6 +268,7 @@ impl> VideoDecoderExtManual for O { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_video_decoder_set_interlaced_output_state")] fn set_interlaced_output_state( &self, fmt: VideoFormat, @@ -287,6 +299,7 @@ impl> VideoDecoderExtManual for O { } } + #[doc(alias = "gst_video_decoder_negotiate")] fn negotiate<'a>( &'a self, output_state: VideoCodecState<'a, InNegotiation<'a>>, diff --git a/gstreamer-video/src/video_encoder.rs b/gstreamer-video/src/video_encoder.rs index aedaa7d28..d7f54d9d0 100644 --- a/gstreamer-video/src/video_encoder.rs +++ b/gstreamer-video/src/video_encoder.rs @@ -12,6 +12,7 @@ use std::ptr; pub trait VideoEncoderExtManual: 'static { #[cfg(any(feature = "v1_12", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))] + #[doc(alias = "gst_video_encoder_allocate_output_frame")] fn allocate_output_frame( &self, frame: &mut VideoCodecFrame, @@ -19,15 +20,20 @@ pub trait VideoEncoderExtManual: 'static { ) -> Result; #[doc(alias = "get_frame")] + #[doc(alias = "gst_video_encoder_get_frame")] fn frame(&self, frame_number: i32) -> Option; #[doc(alias = "get_frames")] + #[doc(alias = "gst_video_encoder_get_frames")] fn frames(&self) -> Vec; #[doc(alias = "get_oldest_frame")] + #[doc(alias = "gst_video_encoder_get_oldest_frame")] fn oldest_frame(&self) -> Option; #[doc(alias = "get_allocator")] + #[doc(alias = "gst_video_encoder_get_allocator")] fn allocator(&self) -> (Option, gst::AllocationParams); + #[doc(alias = "gst_video_encoder_finish_frame")] fn finish_frame( &self, frame: Option, @@ -35,20 +41,26 @@ pub trait VideoEncoderExtManual: 'static { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_video_encoder_finish_subframe")] fn finish_subframe(&self, frame: &VideoCodecFrame) -> Result; #[doc(alias = "get_latency")] + #[doc(alias = "gst_video_encoder_get_latency")] fn latency(&self) -> (gst::ClockTime, gst::ClockTime); + #[doc(alias = "gst_video_encoder_set_latency")] fn set_latency(&self, min_latency: gst::ClockTime, max_latency: gst::ClockTime); #[doc(alias = "get_output_state")] + #[doc(alias = "gst_video_encoder_get_output_state")] fn output_state(&self) -> Option>; + #[doc(alias = "gst_video_encoder_set_output_state")] fn set_output_state( &self, caps: gst::Caps, reference: Option<&VideoCodecState>, ) -> Result, gst::FlowError>; + #[doc(alias = "gst_video_encoder_negotiate")] fn negotiate<'a>( &'a self, output_state: VideoCodecState<'a, InNegotiation<'a>>, diff --git a/gstreamer-video/src/video_event.rs b/gstreamer-video/src/video_event.rs index 6447e5f00..f74c12e60 100644 --- a/gstreamer-video/src/video_event.rs +++ b/gstreamer-video/src/video_event.rs @@ -144,6 +144,7 @@ impl DownstreamForceKeyUnitEvent { DownstreamForceKeyUnitEventBuilder::new() } + #[doc(alias = "gst_video_event_parse_downstream_force_key_unit")] pub fn parse(event: &gst::EventRef) -> Result { skip_assert_initialized!(); unsafe { @@ -237,6 +238,7 @@ impl UpstreamForceKeyUnitEvent { UpstreamForceKeyUnitEventBuilder::new() } + #[doc(alias = "gst_video_event_parse_upstream_force_key_unit")] pub fn parse(event: &gst::EventRef) -> Result { skip_assert_initialized!(); unsafe { @@ -270,6 +272,7 @@ pub enum ForceKeyUnitEvent { } impl ForceKeyUnitEvent { + #[doc(alias = "gst_video_event_is_force_key_unit")] pub fn is(event: &gst::EventRef) -> bool { skip_assert_initialized!(); unsafe { from_glib(ffi::gst_video_event_is_force_key_unit(event.as_mut_ptr())) } @@ -319,6 +322,7 @@ impl StillFrameEvent { StillFrameEventBuilder::new(in_still) } + #[doc(alias = "gst_video_event_parse_still_frame")] pub fn parse(event: &gst::EventRef) -> Result { skip_assert_initialized!(); unsafe { diff --git a/gstreamer-video/src/video_format.rs b/gstreamer-video/src/video_format.rs index 0382dec7c..0739fcc78 100644 --- a/gstreamer-video/src/video_format.rs +++ b/gstreamer-video/src/video_format.rs @@ -282,6 +282,7 @@ impl IntoGlib for VideoEndianness { } impl crate::VideoFormat { + #[doc(alias = "gst_video_format_from_masks")] pub fn from_masks( depth: u32, bpp: u32, @@ -306,6 +307,7 @@ impl crate::VideoFormat { } } + #[doc(alias = "gst_video_format_to_string")] pub fn to_str<'a>(self) -> &'a str { if self == Self::Unknown { return "UNKNOWN"; diff --git a/gstreamer-video/src/video_frame.rs b/gstreamer-video/src/video_frame.rs index 0a4c38acf..c422267be 100644 --- a/gstreamer-video/src/video_frame.rs +++ b/gstreamer-video/src/video_frame.rs @@ -50,6 +50,7 @@ impl VideoFrame { self.buffer.take().unwrap() } + #[doc(alias = "gst_video_frame_copy")] pub fn copy(&self, dest: &mut VideoFrame) -> Result<(), glib::BoolError> { unsafe { let res: bool = from_glib(ffi::gst_video_frame_copy(&mut dest.frame, &self.frame)); @@ -61,6 +62,7 @@ impl VideoFrame { } } + #[doc(alias = "gst_video_frame_copy_plane")] pub fn copy_plane( &self, dest: &mut VideoFrame, @@ -421,6 +423,7 @@ impl VideoFrameRef { self.frame.id } + #[doc(alias = "gst_video_frame_copy")] pub fn copy( &self, dest: &mut VideoFrameRef<&mut gst::BufferRef>, @@ -435,6 +438,7 @@ impl VideoFrameRef { } } + #[doc(alias = "gst_video_frame_copy_plane")] pub fn copy_plane( &self, dest: &mut VideoFrameRef<&mut gst::BufferRef>, diff --git a/gstreamer-video/src/video_info.rs b/gstreamer-video/src/video_info.rs index 5b4f93ad4..235c7a132 100644 --- a/gstreamer-video/src/video_info.rs +++ b/gstreamer-video/src/video_info.rs @@ -127,6 +127,7 @@ impl Clone for VideoColorimetry { } impl PartialEq for VideoColorimetry { + #[doc(alias = "gst_video_colorimetry_is_equal")] fn eq(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_video_colorimetry_is_equal(&self.0, &other.0)) } } @@ -137,6 +138,7 @@ impl Eq for VideoColorimetry {} impl str::FromStr for crate::VideoColorimetry { type Err = glib::error::BoolError; + #[doc(alias = "gst_video_colorimetry_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); @@ -175,6 +177,8 @@ impl fmt::Display for crate::VideoColorimetry { } impl crate::VideoChromaSite { + #[doc(alias = "gst_video_chroma_site_to_string")] + #[doc(alias = "gst_video_chroma_to_string")] pub fn to_str(self) -> glib::GString { assert_initialized_main_thread!(); @@ -193,6 +197,7 @@ impl crate::VideoChromaSite { impl str::FromStr for crate::VideoChromaSite { type Err = glib::error::BoolError; + #[doc(alias = "gst_video_chroma_from_string")] fn from_str(s: &str) -> Result { skip_assert_initialized!(); @@ -598,6 +603,7 @@ impl VideoInfo { !self.0.finfo.is_null() && self.0.width > 0 && self.0.height > 0 && self.0.size > 0 } + #[doc(alias = "gst_video_info_from_caps")] pub fn from_caps(caps: &gst::CapsRef) -> Result { skip_assert_initialized!(); @@ -614,6 +620,7 @@ impl VideoInfo { } } + #[doc(alias = "gst_video_info_to_caps")] pub fn to_caps(&self) -> Result { unsafe { let result = from_glib_full(ffi::gst_video_info_to_caps(&self.0 as *const _ as *mut _)); @@ -745,6 +752,7 @@ impl VideoInfo { self.format_info().n_components() } + #[doc(alias = "gst_video_info_convert")] pub fn convert, U: gst::SpecificFormattedValue>( &self, src_val: V, @@ -795,6 +803,7 @@ impl VideoInfo { } } + #[doc(alias = "gst_video_info_align")] pub fn align(&mut self, align: &mut crate::VideoAlignment) -> Result<(), glib::BoolError> { cfg_if::cfg_if! { if #[cfg(feature = "v1_12")] { @@ -825,6 +834,7 @@ impl VideoInfo { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_video_info_align_full")] pub fn align_full( &mut self, align: &mut crate::VideoAlignment, @@ -854,6 +864,7 @@ impl Clone for VideoInfo { } impl PartialEq for VideoInfo { + #[doc(alias = "gst_video_info_is_equal")] fn eq(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_video_info_is_equal(&self.0, &other.0)) } } @@ -965,6 +976,7 @@ impl glib::translate::FromGlibPtrFull<*mut ffi::GstVideoInfo> for VideoInfo { #[cfg(any(feature = "v1_12", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))] impl crate::VideoFieldOrder { + #[doc(alias = "gst_video_field_order_to_string")] pub fn to_str<'a>(self) -> &'a str { use std::ffi::CStr; diff --git a/gstreamer-video/src/video_meta.rs b/gstreamer-video/src/video_meta.rs index a6103626d..b0c72a225 100644 --- a/gstreamer-video/src/video_meta.rs +++ b/gstreamer-video/src/video_meta.rs @@ -13,6 +13,7 @@ unsafe impl Send for VideoMeta {} unsafe impl Sync for VideoMeta {} impl VideoMeta { + #[doc(alias = "gst_buffer_add_video_meta")] pub fn add( buffer: &mut gst::BufferRef, flags: crate::VideoFrameFlags, @@ -166,6 +167,7 @@ impl VideoMeta { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] #[doc(alias = "get_plane_size")] + #[doc(alias = "gst_video_meta_get_plane_size")] pub fn plane_size(&self) -> Result<[usize; crate::VIDEO_MAX_PLANES], glib::BoolError> { let mut plane_size = [0; crate::VIDEO_MAX_PLANES]; @@ -185,6 +187,7 @@ impl VideoMeta { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] #[doc(alias = "get_plane_height")] + #[doc(alias = "gst_video_meta_get_plane_height")] pub fn plane_height(&self) -> Result<[u32; crate::VIDEO_MAX_PLANES], glib::BoolError> { let mut plane_height = [0; crate::VIDEO_MAX_PLANES]; @@ -203,6 +206,7 @@ impl VideoMeta { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_video_meta_set_alignment")] pub fn set_alignment( &mut self, alignment: &crate::VideoAlignment, @@ -219,6 +223,7 @@ impl VideoMeta { unsafe impl MetaAPI for VideoMeta { type GstType = ffi::GstVideoMeta; + #[doc(alias = "gst_video_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_meta_api_get_type()) } } @@ -246,6 +251,7 @@ unsafe impl Send for VideoCropMeta {} unsafe impl Sync for VideoCropMeta {} impl VideoCropMeta { + #[doc(alias = "gst_buffer_add_meta")] pub fn add( buffer: &mut gst::BufferRef, rect: (u32, u32, u32, u32), @@ -286,6 +292,7 @@ impl VideoCropMeta { unsafe impl MetaAPI for VideoCropMeta { type GstType = ffi::GstVideoCropMeta; + #[doc(alias = "gst_video_crop_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_crop_meta_api_get_type()) } } @@ -306,6 +313,7 @@ unsafe impl Send for VideoRegionOfInterestMeta {} unsafe impl Sync for VideoRegionOfInterestMeta {} impl VideoRegionOfInterestMeta { + #[doc(alias = "gst_buffer_add_video_region_of_interest_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, roi_type: &str, @@ -377,6 +385,7 @@ impl VideoRegionOfInterestMeta { } #[cfg(feature = "v1_14")] + #[doc(alias = "gst_video_region_of_interest_meta_add_param")] pub fn add_param(&mut self, s: gst::Structure) { unsafe { ffi::gst_video_region_of_interest_meta_add_param(&mut self.0, s.into_ptr()); @@ -414,6 +423,7 @@ impl<'a> Iterator for ParamsIter<'a> { unsafe impl MetaAPI for VideoRegionOfInterestMeta { type GstType = ffi::GstVideoRegionOfInterestMeta; + #[doc(alias = "gst_video_region_of_interest_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_region_of_interest_meta_api_get_type()) } } @@ -444,6 +454,7 @@ unsafe impl Send for VideoAffineTransformationMeta {} unsafe impl Sync for VideoAffineTransformationMeta {} impl VideoAffineTransformationMeta { + #[doc(alias = "gst_buffer_add_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, matrix: Option<&[f32; 16]>, @@ -474,6 +485,7 @@ impl VideoAffineTransformationMeta { self.0.matrix.copy_from_slice(matrix); } + #[doc(alias = "gst_video_affine_transformation_meta_apply_matrix")] pub fn apply_matrix(&mut self, matrix: &[f32; 16]) { unsafe { ffi::gst_video_affine_transformation_meta_apply_matrix(&mut self.0, matrix); @@ -484,6 +496,7 @@ impl VideoAffineTransformationMeta { unsafe impl MetaAPI for VideoAffineTransformationMeta { type GstType = ffi::GstVideoAffineTransformationMeta; + #[doc(alias = "gst_video_affine_transformation_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_affine_transformation_meta_api_get_type()) } } @@ -504,6 +517,7 @@ unsafe impl Send for VideoOverlayCompositionMeta {} unsafe impl Sync for VideoOverlayCompositionMeta {} impl VideoOverlayCompositionMeta { + #[doc(alias = "gst_buffer_add_video_overlay_composition_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, overlay: &crate::VideoOverlayComposition, @@ -542,6 +556,7 @@ impl VideoOverlayCompositionMeta { unsafe impl MetaAPI for VideoOverlayCompositionMeta { type GstType = ffi::GstVideoOverlayCompositionMeta; + #[doc(alias = "gst_video_overlay_composition_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_overlay_composition_meta_api_get_type()) } } @@ -570,6 +585,7 @@ unsafe impl Sync for VideoCaptionMeta {} #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] impl VideoCaptionMeta { + #[doc(alias = "gst_buffer_add_video_caption_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, caption_type: crate::VideoCaptionType, @@ -609,6 +625,7 @@ impl VideoCaptionMeta { unsafe impl MetaAPI for VideoCaptionMeta { type GstType = ffi::GstVideoCaptionMeta; + #[doc(alias = "gst_video_caption_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_caption_meta_api_get_type()) } } @@ -640,6 +657,7 @@ unsafe impl Sync for VideoAFDMeta {} #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] impl VideoAFDMeta { + #[doc(alias = "gst_buffer_add_video_afd_meta")] pub fn add( buffer: &mut gst::BufferRef, field: u8, @@ -681,6 +699,7 @@ impl VideoAFDMeta { unsafe impl MetaAPI for VideoAFDMeta { type GstType = ffi::GstVideoAFDMeta; + #[doc(alias = "gst_video_afd_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_afd_meta_api_get_type()) } } @@ -713,6 +732,7 @@ unsafe impl Sync for VideoBarMeta {} #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] impl VideoBarMeta { + #[doc(alias = "gst_buffer_add_video_bar_meta")] pub fn add( buffer: &mut gst::BufferRef, field: u8, @@ -760,6 +780,7 @@ impl VideoBarMeta { unsafe impl MetaAPI for VideoBarMeta { type GstType = ffi::GstVideoBarMeta; + #[doc(alias = "gst_video_bar_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_bar_meta_api_get_type()) } } diff --git a/gstreamer-video/src/video_overlay.rs b/gstreamer-video/src/video_overlay.rs index 2024ba5a5..70a212b02 100644 --- a/gstreamer-video/src/video_overlay.rs +++ b/gstreamer-video/src/video_overlay.rs @@ -21,6 +21,7 @@ impl> VideoOverlayExtManual for O { } } +#[doc(alias = "gst_is_video_overlay_prepare_window_handle_message")] pub fn is_video_overlay_prepare_window_handle_message(msg: &gst::MessageRef) -> bool { skip_assert_initialized!(); unsafe { diff --git a/gstreamer-video/src/video_overlay_composition.rs b/gstreamer-video/src/video_overlay_composition.rs index 1e748e9e5..691e71b7a 100644 --- a/gstreamer-video/src/video_overlay_composition.rs +++ b/gstreamer-video/src/video_overlay_composition.rs @@ -29,6 +29,7 @@ impl fmt::Debug for VideoOverlayRectangleRef { } impl VideoOverlayRectangle { + #[doc(alias = "gst_video_overlay_rectangle_new_raw")] pub fn new_raw( buffer: &gst::Buffer, render_x: i32, @@ -54,6 +55,7 @@ impl VideoOverlayRectangle { impl VideoOverlayRectangleRef { #[doc(alias = "get_flags")] + #[doc(alias = "gst_video_overlay_rectangle_get_flags")] pub fn flags(&self) -> crate::VideoOverlayFormatFlags { unsafe { from_glib(ffi::gst_video_overlay_rectangle_get_flags( @@ -63,20 +65,24 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_global_alpha")] + #[doc(alias = "gst_video_overlay_rectangle_get_global_alpha")] pub fn global_alpha(&self) -> f32 { unsafe { ffi::gst_video_overlay_rectangle_get_global_alpha(self.as_mut_ptr()) } } + #[doc(alias = "gst_video_overlay_rectangle_set_global_alpha")] pub fn set_global_alpha(&mut self, alpha: f32) { unsafe { ffi::gst_video_overlay_rectangle_set_global_alpha(self.as_mut_ptr(), alpha) } } #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_video_overlay_rectangle_get_seqnum")] pub fn seqnum(&self) -> u32 { unsafe { ffi::gst_video_overlay_rectangle_get_seqnum(self.as_mut_ptr()) } } #[doc(alias = "get_render_rectangle")] + #[doc(alias = "gst_video_overlay_rectangle_get_render_rectangle")] pub fn render_rectangle(&self) -> (i32, i32, u32, u32) { unsafe { let mut render_x = mem::MaybeUninit::uninit(); @@ -101,6 +107,7 @@ impl VideoOverlayRectangleRef { } } + #[doc(alias = "gst_video_overlay_rectangle_set_render_rectangle")] pub fn set_render_rectangle( &mut self, render_x: i32, @@ -120,6 +127,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_unscaled_raw")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_unscaled_raw")] pub fn pixels_unscaled_raw(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_unscaled_raw( @@ -130,6 +138,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_unscaled_ayuv")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_unscaled_ayuv")] pub fn pixels_unscaled_ayuv(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_unscaled_ayuv( @@ -140,6 +149,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_unscaled_argb")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_unscaled_argb")] pub fn pixels_unscaled_argb(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_unscaled_argb( @@ -150,6 +160,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_raw")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_raw")] pub fn pixels_raw(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_raw( @@ -160,6 +171,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_ayuv")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_ayuv")] pub fn pixels_ayuv(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_ayuv( @@ -170,6 +182,7 @@ impl VideoOverlayRectangleRef { } #[doc(alias = "get_pixels_argb")] + #[doc(alias = "gst_video_overlay_rectangle_get_pixels_argb")] pub fn pixels_argb(&self, flags: crate::VideoOverlayFormatFlags) -> gst::Buffer { unsafe { from_glib_none(ffi::gst_video_overlay_rectangle_get_pixels_argb( @@ -200,6 +213,7 @@ impl fmt::Debug for VideoOverlayCompositionRef { } impl VideoOverlayComposition { + #[doc(alias = "gst_video_overlay_composition_new")] pub fn new<'a, T: IntoIterator>( rects: T, ) -> Result { @@ -232,11 +246,13 @@ impl VideoOverlayComposition { } impl VideoOverlayCompositionRef { + #[doc(alias = "gst_video_overlay_composition_n_rectangles")] pub fn n_rectangles(&self) -> u32 { unsafe { ffi::gst_video_overlay_composition_n_rectangles(self.as_mut_ptr()) } } #[doc(alias = "get_rectangle")] + #[doc(alias = "gst_video_overlay_composition_get_rectangle")] pub fn rectangle(&self, idx: u32) -> Result { if idx >= self.n_rectangles() { return Err(glib::bool_error!("Invalid index")); @@ -254,10 +270,12 @@ impl VideoOverlayCompositionRef { } #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_video_overlay_composition_get_seqnum")] pub fn seqnum(&self) -> u32 { unsafe { ffi::gst_video_overlay_composition_get_seqnum(self.as_mut_ptr()) } } + #[doc(alias = "gst_video_overlay_composition_blend")] pub fn blend( &self, frame: &mut crate::VideoFrameRef<&mut gst::BufferRef>, diff --git a/gstreamer-video/src/video_time_code.rs b/gstreamer-video/src/video_time_code.rs index 6f82c8eb8..678900ab4 100644 --- a/gstreamer-video/src/video_time_code.rs +++ b/gstreamer-video/src/video_time_code.rs @@ -62,6 +62,7 @@ impl VideoTimeCode { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_video_time_code_init_from_date_time_full")] pub fn from_date_time( fps: gst::Fraction, dt: &glib::DateTime, @@ -89,6 +90,7 @@ impl VideoTimeCode { } } + #[doc(alias = "gst_video_time_code_is_valid")] pub fn is_valid(&self) -> bool { unsafe { from_glib(ffi::gst_video_time_code_is_valid(self.to_glib_none().0)) } } @@ -183,6 +185,7 @@ impl ValidVideoTimeCode { // tc.and_then(|tc| tc.try_into().ok()) // } + #[doc(alias = "gst_video_time_code_add_frames")] pub fn add_frames(&mut self, frames: i64) { skip_assert_initialized!(); unsafe { @@ -192,6 +195,7 @@ impl ValidVideoTimeCode { #[cfg(any(feature = "v1_12", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))] + #[doc(alias = "gst_video_time_code_add_interval")] pub fn add_interval( &self, tc_inter: &VideoTimeCodeInterval, @@ -207,24 +211,29 @@ impl ValidVideoTimeCode { } } + #[doc(alias = "gst_video_time_code_compare")] fn compare(&self, tc2: &Self) -> i32 { unsafe { ffi::gst_video_time_code_compare(self.to_glib_none().0, tc2.to_glib_none().0) } } + #[doc(alias = "gst_video_time_code_frames_since_daily_jam")] pub fn frames_since_daily_jam(&self) -> u64 { unsafe { ffi::gst_video_time_code_frames_since_daily_jam(self.to_glib_none().0) } } + #[doc(alias = "gst_video_time_code_increment_frame")] pub fn increment_frame(&mut self) { unsafe { ffi::gst_video_time_code_increment_frame(self.to_glib_none_mut().0); } } + #[doc(alias = "gst_video_time_code_nsec_since_daily_jam")] pub fn nsec_since_daily_jam(&self) -> u64 { unsafe { ffi::gst_video_time_code_nsec_since_daily_jam(self.to_glib_none().0) } } + #[doc(alias = "gst_video_time_code_to_date_time")] pub fn to_date_time(&self) -> Result { unsafe { match from_glib_full(ffi::gst_video_time_code_to_date_time(self.to_glib_none().0)) { @@ -485,6 +494,7 @@ generic_impl!(ValidVideoTimeCode); impl str::FromStr for VideoTimeCode { type Err = glib::error::BoolError; + #[doc(alias = "gst_video_time_code_new_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); unsafe { @@ -537,6 +547,7 @@ unsafe impl Send for VideoTimeCodeMeta {} unsafe impl Sync for VideoTimeCodeMeta {} impl VideoTimeCodeMeta { + #[doc(alias = "gst_buffer_add_video_time_code_meta")] pub fn add<'a>( buffer: &'a mut gst::BufferRef, tc: &ValidVideoTimeCode, @@ -573,6 +584,7 @@ impl VideoTimeCodeMeta { unsafe impl MetaAPI for VideoTimeCodeMeta { type GstType = ffi::GstVideoTimeCodeMeta; + #[doc(alias = "gst_video_time_code_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_video_time_code_meta_api_get_type()) } } diff --git a/gstreamer-video/src/video_time_code_interval.rs b/gstreamer-video/src/video_time_code_interval.rs index f86f12c43..88a8f6861 100644 --- a/gstreamer-video/src/video_time_code_interval.rs +++ b/gstreamer-video/src/video_time_code_interval.rs @@ -117,6 +117,7 @@ impl fmt::Display for VideoTimeCodeInterval { impl str::FromStr for VideoTimeCodeInterval { type Err = glib::error::BoolError; + #[doc(alias = "gst_video_time_code_interval_new_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); unsafe { diff --git a/gstreamer-webrtc/src/web_rtc_data_channel.rs b/gstreamer-webrtc/src/web_rtc_data_channel.rs index 74d5fa02b..f3a0ee842 100644 --- a/gstreamer-webrtc/src/web_rtc_data_channel.rs +++ b/gstreamer-webrtc/src/web_rtc_data_channel.rs @@ -4,6 +4,7 @@ use crate::WebRTCDataChannel; use glib::translate::*; impl WebRTCDataChannel { + #[doc(alias = "gst_webrtc_data_channel_on_error")] pub fn on_error(&self, error: glib::Error) { unsafe { ffi::gst_webrtc_data_channel_on_error(self.to_glib_none().0, error.into_raw()); diff --git a/gstreamer-webrtc/src/web_rtc_session_description.rs b/gstreamer-webrtc/src/web_rtc_session_description.rs index a5dec0a21..621ff7544 100644 --- a/gstreamer-webrtc/src/web_rtc_session_description.rs +++ b/gstreamer-webrtc/src/web_rtc_session_description.rs @@ -6,6 +6,7 @@ use glib::translate::*; use std::mem; impl WebRTCSessionDescription { + #[doc(alias = "gst_webrtc_session_description_new")] pub fn new(type_: WebRTCSDPType, sdp: gst_sdp::SDPMessage) -> WebRTCSessionDescription { assert_initialized_main_thread!(); unsafe { diff --git a/gstreamer/src/bin.rs b/gstreamer/src/bin.rs index 327f271c3..87e17df7a 100644 --- a/gstreamer/src/bin.rs +++ b/gstreamer/src/bin.rs @@ -26,12 +26,19 @@ pub trait GstBinExtManual: 'static { #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] + #[doc(alias = "gst_bin_iterate_all_by_element_factory_name")] fn iterate_all_by_element_factory_name(&self, factory_name: &str) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_all_by_interface")] fn iterate_all_by_interface(&self, iface: glib::types::Type) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_elements")] fn iterate_elements(&self) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_recurse")] fn iterate_recurse(&self) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_sinks")] fn iterate_sinks(&self) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_sorted")] fn iterate_sorted(&self) -> crate::Iterator; + #[doc(alias = "gst_bin_iterate_sources")] fn iterate_sources(&self) -> crate::Iterator; #[doc(alias = "get_children")] fn children(&self) -> Vec; diff --git a/gstreamer/src/buffer.rs b/gstreamer/src/buffer.rs index 72b93d349..2f3878987 100644 --- a/gstreamer/src/buffer.rs +++ b/gstreamer/src/buffer.rs @@ -39,6 +39,7 @@ pub struct MappedBuffer { } impl Buffer { + #[doc(alias = "gst_buffer_new")] pub fn new() -> Self { assert_initialized_main_thread!(); @@ -155,6 +156,7 @@ impl Buffer { BufferCursor::new_writable(self) } + #[doc(alias = "gst_buffer_append")] pub fn append(&mut self, other: Self) { skip_assert_initialized!(); unsafe { @@ -208,6 +210,7 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_copy_region")] pub fn copy_region( &self, flags: crate::BufferCopyFlags, @@ -226,6 +229,7 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_copy_into")] pub fn copy_into( &self, dest: &mut BufferRef, @@ -289,6 +293,7 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_copy_deep")] pub fn copy_deep(&self) -> Result { unsafe { Option::<_>::from_glib_full(ffi::gst_buffer_copy_deep(self.as_ptr())) @@ -297,6 +302,7 @@ impl BufferRef { } #[doc(alias = "get_size")] + #[doc(alias = "gst_buffer_get_size")] pub fn size(&self) -> usize { unsafe { ffi::gst_buffer_get_size(self.as_mut_ptr()) } } @@ -317,6 +323,7 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_set_size")] pub fn set_size(&mut self, size: usize) { assert!(self.maxsize() >= size); @@ -394,6 +401,7 @@ impl BufferRef { } #[doc(alias = "get_meta")] + #[doc(alias = "gst_buffer_get_meta")] pub fn meta(&self) -> Option> { unsafe { let meta = ffi::gst_buffer_get_meta(self.as_mut_ptr(), T::meta_api().into_glib()); @@ -425,6 +433,7 @@ impl BufferRef { MetaIterMut::new(self) } + #[doc(alias = "gst_buffer_foreach_meta")] pub fn foreach_meta) -> bool>(&self, func: F) -> bool { unsafe extern "C" fn trampoline) -> bool>( buffer: *mut ffi::GstBuffer, @@ -484,10 +493,12 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_append_memory")] pub fn append_memory(&mut self, mem: Memory) { unsafe { ffi::gst_buffer_append_memory(self.as_mut_ptr(), mem.into_ptr()) } } + #[doc(alias = "gst_buffer_find_memory")] pub fn find_memory(&self, offset: usize, size: Option) -> Option<(u32, u32, usize)> { unsafe { let mut idx = mem::MaybeUninit::uninit(); @@ -512,6 +523,7 @@ impl BufferRef { } #[doc(alias = "get_all_memory")] + #[doc(alias = "gst_buffer_get_all_memory")] pub fn all_memory(&self) -> Option { unsafe { let res = ffi::gst_buffer_get_all_memory(self.as_mut_ptr()); @@ -524,11 +536,13 @@ impl BufferRef { } #[doc(alias = "get_max_memory")] + #[doc(alias = "gst_buffer_get_max_memory")] pub fn max_memory() -> u32 { unsafe { ffi::gst_buffer_get_max_memory() } } #[doc(alias = "get_memory")] + #[doc(alias = "gst_buffer_get_memory")] pub fn memory(&self, idx: u32) -> Option { if idx >= self.n_memory() { None @@ -545,6 +559,7 @@ impl BufferRef { } #[doc(alias = "get_memory_range")] + #[doc(alias = "gst_buffer_get_memory_range")] pub fn memory_range(&self, idx: u32, length: Option) -> Option { assert!(idx + length.unwrap_or(0) < self.n_memory()); unsafe { @@ -564,6 +579,7 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_insert_memory")] pub fn insert_memory(&mut self, idx: Option, mem: Memory) { unsafe { ffi::gst_buffer_insert_memory( @@ -577,10 +593,12 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_is_all_memory_writable")] pub fn is_all_memory_writable(&self) -> bool { unsafe { from_glib(ffi::gst_buffer_is_all_memory_writable(self.as_mut_ptr())) } } + #[doc(alias = "gst_buffer_is_memory_range_writable")] pub fn is_memory_range_writable(&self, idx: u32, length: Option) -> bool { unsafe { from_glib(ffi::gst_buffer_is_memory_range_writable( @@ -594,10 +612,12 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_n_memory")] pub fn n_memory(&self) -> u32 { unsafe { ffi::gst_buffer_n_memory(self.as_ptr() as *mut _) } } + #[doc(alias = "gst_buffer_peek_memory")] pub fn peek_memory(&self, idx: u32) -> &MemoryRef { assert!(idx < self.n_memory()); unsafe { MemoryRef::from_ptr(ffi::gst_buffer_peek_memory(self.as_mut_ptr(), idx)) } @@ -618,19 +638,23 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_prepend_memory")] pub fn prepend_memory(&mut self, mem: Memory) { unsafe { ffi::gst_buffer_prepend_memory(self.as_mut_ptr(), mem.into_ptr()) } } + #[doc(alias = "gst_buffer_remove_all_memory")] pub fn remove_all_memory(&mut self) { unsafe { ffi::gst_buffer_remove_all_memory(self.as_mut_ptr()) } } + #[doc(alias = "gst_buffer_remove_memory")] pub fn remove_memory(&mut self, idx: u32) { assert!(idx < self.n_memory()); unsafe { ffi::gst_buffer_remove_memory(self.as_mut_ptr(), idx) } } + #[doc(alias = "gst_buffer_remove_memory_range")] pub fn remove_memory_range(&mut self, idx: u32, length: Option) { assert!(idx + length.unwrap_or(0) < self.n_memory()); unsafe { @@ -645,15 +669,18 @@ impl BufferRef { } } + #[doc(alias = "gst_buffer_replace_all_memory")] pub fn replace_all_memory(&mut self, mem: Memory) { unsafe { ffi::gst_buffer_replace_all_memory(self.as_mut_ptr(), mem.into_ptr()) } } + #[doc(alias = "gst_buffer_replace_memory")] pub fn replace_memory(&mut self, idx: u32, mem: Memory) { assert!(idx < self.n_memory()); unsafe { ffi::gst_buffer_replace_memory(self.as_mut_ptr(), idx, mem.into_ptr()) } } + #[doc(alias = "gst_buffer_replace_memory_range")] pub fn replace_memory_range(&mut self, idx: u32, length: Option, mem: Memory) { assert!(idx + length.unwrap_or(0) < self.n_memory()); unsafe { diff --git a/gstreamer/src/buffer_pool.rs b/gstreamer/src/buffer_pool.rs index 918064237..95428695e 100644 --- a/gstreamer/src/buffer_pool.rs +++ b/gstreamer/src/buffer_pool.rs @@ -42,6 +42,7 @@ impl AsMut for BufferPoolConfig { } impl BufferPoolConfig { + #[doc(alias = "gst_buffer_pool_config_add_option")] pub fn add_option(&mut self, option: &str) { unsafe { ffi::gst_buffer_pool_config_add_option( @@ -51,6 +52,7 @@ impl BufferPoolConfig { } } + #[doc(alias = "gst_buffer_pool_config_has_option")] pub fn has_option(&self, option: &str) -> bool { unsafe { from_glib(ffi::gst_buffer_pool_config_has_option( @@ -61,6 +63,7 @@ impl BufferPoolConfig { } #[doc(alias = "get_options")] + #[doc(alias = "gst_buffer_pool_config_n_options")] pub fn options(&self) -> Vec { unsafe { let n = ffi::gst_buffer_pool_config_n_options(self.0.to_glib_none().0) as usize; @@ -77,6 +80,7 @@ impl BufferPoolConfig { } } + #[doc(alias = "gst_buffer_pool_config_set_params")] pub fn set_params( &mut self, caps: Option<&crate::Caps>, @@ -96,6 +100,7 @@ impl BufferPoolConfig { } #[doc(alias = "get_params")] + #[doc(alias = "gst_buffer_pool_config_get_params")] pub fn params(&self) -> Option<(Option, u32, u32, u32)> { unsafe { let mut caps = ptr::null_mut(); @@ -123,6 +128,7 @@ impl BufferPoolConfig { } } + #[doc(alias = "gst_buffer_pool_config_validate_params")] pub fn validate_params( &self, caps: Option<&crate::Caps>, @@ -145,6 +151,7 @@ impl BufferPoolConfig { } #[doc(alias = "get_allocator")] + #[doc(alias = "gst_buffer_pool_config_get_allocator")] pub fn allocator(&self) -> Option<(Option, AllocationParams)> { unsafe { let mut allocator = ptr::null_mut(); @@ -162,6 +169,7 @@ impl BufferPoolConfig { } } + #[doc(alias = "gst_buffer_pool_config_set_allocator")] pub fn set_allocator(&self, allocator: Option<&Allocator>, params: Option<&AllocationParams>) { assert!(allocator.is_some() || params.is_some()); unsafe { @@ -263,6 +271,7 @@ impl<'a> ToGlibPtrMut<'a, *mut ffi::GstBufferPoolAcquireParams> for BufferPoolAc } impl BufferPool { + #[doc(alias = "gst_buffer_pool_new")] pub fn new() -> BufferPool { assert_initialized_main_thread!(); let (major, minor, _, _) = crate::version(); @@ -283,15 +292,19 @@ impl Default for BufferPool { pub trait BufferPoolExtManual: 'static { #[doc(alias = "get_config")] + #[doc(alias = "gst_buffer_pool_get_config")] fn config(&self) -> BufferPoolConfig; + #[doc(alias = "gst_buffer_pool_set_config")] fn set_config(&self, config: BufferPoolConfig) -> Result<(), glib::error::BoolError>; fn is_flushing(&self) -> bool; + #[doc(alias = "gst_buffer_pool_acquire_buffer")] fn acquire_buffer( &self, params: Option<&BufferPoolAcquireParams>, ) -> Result; + #[doc(alias = "gst_buffer_pool_release_buffer")] fn release_buffer(&self, buffer: crate::Buffer); } diff --git a/gstreamer/src/bufferlist.rs b/gstreamer/src/bufferlist.rs index e16018b42..6da6e280b 100644 --- a/gstreamer/src/bufferlist.rs +++ b/gstreamer/src/bufferlist.rs @@ -12,11 +12,13 @@ mini_object_wrapper!(BufferList, BufferListRef, ffi::GstBufferList, || { }); impl BufferList { + #[doc(alias = "gst_buffer_list_new")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_buffer_list_new()) } } + #[doc(alias = "gst_buffer_list_new_sized")] pub fn new_sized(size: usize) -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_buffer_list_new_sized(size as u32)) } @@ -24,6 +26,7 @@ impl BufferList { } impl BufferListRef { + #[doc(alias = "gst_buffer_list_insert")] pub fn insert(&mut self, idx: i32, buffer: Buffer) { unsafe { ffi::gst_buffer_list_insert(self.as_mut_ptr(), idx, buffer.into_ptr()); @@ -34,14 +37,17 @@ impl BufferListRef { self.insert(-1, buffer); } + #[doc(alias = "gst_buffer_list_copy_deep")] pub fn copy_deep(&self) -> BufferList { unsafe { from_glib_full(ffi::gst_buffer_list_copy_deep(self.as_ptr())) } } + #[doc(alias = "gst_buffer_list_remove")] pub fn remove(&mut self, idx: u32, len: u32) { unsafe { ffi::gst_buffer_list_remove(self.as_mut_ptr(), idx, len) } } + #[doc(alias = "gst_buffer_list_get")] pub fn get(&self, idx: u32) -> Option<&BufferRef> { unsafe { let ptr = ffi::gst_buffer_list_get(self.as_mut_ptr(), idx); @@ -75,12 +81,14 @@ impl BufferListRef { } } + #[doc(alias = "gst_buffer_list_length")] pub fn len(&self) -> usize { unsafe { ffi::gst_buffer_list_length(self.as_mut_ptr()) as usize } } #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_buffer_list_calculate_size")] pub fn calculate_size(&self) -> usize { unsafe { ffi::gst_buffer_list_calculate_size(self.as_mut_ptr()) as usize } } @@ -97,6 +105,7 @@ impl BufferListRef { IterOwned::new(self) } + #[doc(alias = "gst_buffer_list_foreach")] pub fn foreach bool>(&self, func: F) -> bool { unsafe extern "C" fn trampoline bool>( buffer: *mut *mut ffi::GstBuffer, diff --git a/gstreamer/src/bus.rs b/gstreamer/src/bus.rs index 815cbe896..766feb801 100644 --- a/gstreamer/src/bus.rs +++ b/gstreamer/src/bus.rs @@ -72,12 +72,14 @@ fn into_raw_sync BusSyncReply + Send + Sync + 'static>( } impl Bus { + #[doc(alias = "gst_bus_add_signal_watch_full")] pub fn add_signal_watch_full(&self, priority: Priority) { unsafe { ffi::gst_bus_add_signal_watch_full(self.to_glib_none().0, priority.into_glib()); } } + #[doc(alias = "gst_bus_create_watch")] pub fn create_watch(&self, name: Option<&str>, priority: Priority, func: F) -> glib::Source where F: FnMut(&Bus, &Message) -> Continue + Send + 'static, @@ -104,6 +106,7 @@ impl Bus { } } + #[doc(alias = "gst_bus_add_watch_full")] pub fn add_watch(&self, func: F) -> Result where F: FnMut(&Bus, &Message) -> Continue + Send + 'static, @@ -148,6 +151,7 @@ impl Bus { } } + #[doc(alias = "gst_bus_set_sync_handler")] pub fn set_sync_handler(&self, func: F) where F: Fn(&Bus, &Message) -> BusSyncReply + Send + Sync + 'static, diff --git a/gstreamer/src/bus_unix.rs b/gstreamer/src/bus_unix.rs index dfb449830..767dbe721 100644 --- a/gstreamer/src/bus_unix.rs +++ b/gstreamer/src/bus_unix.rs @@ -20,6 +20,7 @@ use super::Bus; pub trait UnixBusExtManual: 'static { #[doc(alias = "get_pollfd")] + #[doc(alias = "gst_bus_get_pollfd")] fn pollfd(&self) -> unix::io::RawFd; } diff --git a/gstreamer/src/bus_windows.rs b/gstreamer/src/bus_windows.rs index 0a94d415e..86ef13cf4 100644 --- a/gstreamer/src/bus_windows.rs +++ b/gstreamer/src/bus_windows.rs @@ -20,6 +20,7 @@ use super::Bus; pub trait WindowsBusExtManual: 'static { #[doc(alias = "get_pollfd")] + #[doc(alias = "gst_bus_get_pollfd")] fn pollfd(&self) -> windows::io::RawHandle; } diff --git a/gstreamer/src/caps.rs b/gstreamer/src/caps.rs index 6e3ff22b8..948a87098 100644 --- a/gstreamer/src/caps.rs +++ b/gstreamer/src/caps.rs @@ -35,11 +35,13 @@ impl Caps { BuilderFull::with_any_features() } + #[doc(alias = "gst_caps_new_empty")] pub fn new_empty() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_caps_new_empty()) } } + #[doc(alias = "gst_caps_new_any")] pub fn new_any() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_caps_new_any()) } @@ -85,6 +87,7 @@ impl Caps { caps } + #[doc(alias = "gst_caps_fixate")] pub fn fixate(&mut self) { skip_assert_initialized!(); unsafe { @@ -99,6 +102,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_merge")] pub fn merge(&mut self, other: Self) { skip_assert_initialized!(); unsafe { @@ -107,6 +111,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_merge_structure")] pub fn merge_structure(&mut self, structure: Structure) { skip_assert_initialized!(); unsafe { @@ -115,6 +120,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_merge_structure_full")] pub fn merge_structure_full(&mut self, structure: Structure, features: Option) { skip_assert_initialized!(); unsafe { @@ -127,6 +133,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_normalize")] pub fn normalize(&mut self) { skip_assert_initialized!(); unsafe { @@ -135,6 +142,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_simplify")] pub fn simplify(&mut self) { skip_assert_initialized!(); unsafe { @@ -143,6 +151,7 @@ impl Caps { } } + #[doc(alias = "gst_caps_truncate")] pub fn truncate(&mut self) { skip_assert_initialized!(); unsafe { @@ -155,6 +164,7 @@ impl Caps { impl str::FromStr for Caps { type Err = glib::BoolError; + #[doc(alias = "gst_caps_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); unsafe { @@ -180,6 +190,7 @@ impl CapsRef { } #[doc(alias = "get_structure")] + #[doc(alias = "gst_caps_get_structure")] pub fn structure(&self, idx: u32) -> Option<&StructureRef> { if idx >= self.size() { return None; @@ -212,6 +223,7 @@ impl CapsRef { } #[doc(alias = "get_features")] + #[doc(alias = "gst_caps_get_features")] pub fn features(&self, idx: u32) -> Option<&CapsFeaturesRef> { if idx >= self.size() { return None; @@ -235,6 +247,7 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_set_features")] pub fn set_features(&mut self, idx: u32, features: Option) { assert!(idx < self.size()); @@ -249,6 +262,7 @@ impl CapsRef { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_caps_set_features_simple")] pub fn set_features_simple(&mut self, features: Option) { unsafe { ffi::gst_caps_set_features_simple( @@ -259,6 +273,7 @@ impl CapsRef { } #[doc(alias = "get_size")] + #[doc(alias = "gst_caps_get_size")] pub fn size(&self) -> u32 { unsafe { ffi::gst_caps_get_size(self.as_ptr()) } } @@ -279,10 +294,12 @@ impl CapsRef { IterFeaturesMut::new(self) } + #[doc(alias = "gst_caps_append_structure")] pub fn append_structure(&mut self, structure: Structure) { unsafe { ffi::gst_caps_append_structure(self.as_mut_ptr(), structure.into_ptr()) } } + #[doc(alias = "gst_caps_append_structure_full")] pub fn append_structure_full(&mut self, structure: Structure, features: Option) { unsafe { ffi::gst_caps_append_structure_full( @@ -293,18 +310,22 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_remove_structure")] pub fn remove_structure(&mut self, idx: u32) { unsafe { ffi::gst_caps_remove_structure(self.as_mut_ptr(), idx) } } + #[doc(alias = "gst_caps_append")] pub fn append(&mut self, other: Caps) { unsafe { ffi::gst_caps_append(self.as_mut_ptr(), other.into_ptr()) } } + #[doc(alias = "gst_caps_can_intersect")] pub fn can_intersect(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_caps_can_intersect(self.as_ptr(), other.as_ptr())) } } + #[doc(alias = "gst_caps_intersect")] pub fn intersect(&self, other: &Self) -> Caps { unsafe { from_glib_full(ffi::gst_caps_intersect( @@ -324,6 +345,7 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_is_always_compatible")] pub fn is_always_compatible(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_caps_is_always_compatible( @@ -333,22 +355,27 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_is_any")] pub fn is_any(&self) -> bool { unsafe { from_glib(ffi::gst_caps_is_any(self.as_ptr())) } } + #[doc(alias = "gst_caps_is_empty")] pub fn is_empty(&self) -> bool { unsafe { from_glib(ffi::gst_caps_is_empty(self.as_ptr())) } } + #[doc(alias = "gst_caps_is_fixed")] pub fn is_fixed(&self) -> bool { unsafe { from_glib(ffi::gst_caps_is_fixed(self.as_ptr())) } } + #[doc(alias = "gst_caps_is_equal_fixed")] pub fn is_equal_fixed(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_caps_is_equal_fixed(self.as_ptr(), other.as_ptr())) } } + #[doc(alias = "gst_caps_is_strictly_equal")] pub fn is_strictly_equal(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_caps_is_strictly_equal( @@ -358,10 +385,12 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_is_subset")] pub fn is_subset(&self, superset: &Self) -> bool { unsafe { from_glib(ffi::gst_caps_is_subset(self.as_ptr(), superset.as_ptr())) } } + #[doc(alias = "gst_caps_is_subset_structure")] pub fn is_subset_structure(&self, structure: &StructureRef) -> bool { unsafe { from_glib(ffi::gst_caps_is_subset_structure( @@ -371,6 +400,7 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_is_subset_structure_full")] pub fn is_subset_structure_full( &self, structure: &StructureRef, @@ -385,6 +415,7 @@ impl CapsRef { } } + #[doc(alias = "gst_caps_subtract")] pub fn subtract(&self, other: &Self) -> Caps { skip_assert_initialized!(); unsafe { @@ -561,6 +592,7 @@ impl fmt::Display for CapsRef { } impl PartialEq for CapsRef { + #[doc(alias = "gst_caps_is_equal")] fn eq(&self, other: &CapsRef) -> bool { unsafe { from_glib(ffi::gst_caps_is_equal(self.as_ptr(), other.as_ptr())) } } diff --git a/gstreamer/src/caps_features.rs b/gstreamer/src/caps_features.rs index 10f75c84a..c5b5e719c 100644 --- a/gstreamer/src/caps_features.rs +++ b/gstreamer/src/caps_features.rs @@ -40,6 +40,7 @@ impl CapsFeatures { f } + #[doc(alias = "gst_caps_features_new_empty")] pub fn new_empty() -> Self { assert_initialized_main_thread!(); unsafe { @@ -49,6 +50,7 @@ impl CapsFeatures { } } + #[doc(alias = "gst_caps_features_new_any")] pub fn new_any() -> Self { assert_initialized_main_thread!(); unsafe { CapsFeatures(ptr::NonNull::new_unchecked(ffi::gst_caps_features_new_any())) } @@ -121,6 +123,7 @@ impl fmt::Display for CapsFeatures { impl str::FromStr for CapsFeatures { type Err = glib::BoolError; + #[doc(alias = "gst_caps_features_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); unsafe { @@ -304,10 +307,12 @@ impl CapsFeaturesRef { self.size() == 0 && !self.is_any() } + #[doc(alias = "gst_caps_features_is_any")] pub fn is_any(&self) -> bool { unsafe { from_glib(ffi::gst_caps_features_is_any(self.as_ptr())) } } + #[doc(alias = "gst_caps_features_contains")] pub fn contains(&self, feature: &str) -> bool { unsafe { from_glib(ffi::gst_caps_features_contains( @@ -327,11 +332,13 @@ impl CapsFeaturesRef { } #[doc(alias = "get_size")] + #[doc(alias = "gst_caps_features_get_size")] pub fn size(&self) -> u32 { unsafe { ffi::gst_caps_features_get_size(self.as_ptr()) } } #[doc(alias = "get_nth")] + #[doc(alias = "gst_caps_features_get_nth")] pub fn nth(&self, idx: u32) -> Option<&str> { if idx >= self.size() { return None; @@ -358,10 +365,12 @@ impl CapsFeaturesRef { } } + #[doc(alias = "gst_caps_features_add")] pub fn add(&mut self, feature: &str) { unsafe { ffi::gst_caps_features_add(self.as_mut_ptr(), feature.to_glib_none().0) } } + #[doc(alias = "gst_caps_features_remove")] pub fn remove(&mut self, feature: &str) { unsafe { ffi::gst_caps_features_remove(self.as_mut_ptr(), feature.to_glib_none().0) } } @@ -379,6 +388,7 @@ impl CapsFeaturesRef { } // This is not an equivalence relation with regards to ANY. Everything is equal to ANY + #[doc(alias = "gst_caps_features_is_equal")] pub fn is_equal(&self, other: &CapsFeaturesRef) -> bool { unsafe { from_glib(ffi::gst_caps_features_is_equal( diff --git a/gstreamer/src/clock.rs b/gstreamer/src/clock.rs index 09604ca76..2455dfadd 100644 --- a/gstreamer/src/clock.rs +++ b/gstreamer/src/clock.rs @@ -34,14 +34,17 @@ glib::wrapper! { impl ClockId { #[doc(alias = "get_time")] + #[doc(alias = "gst_clock_id_get_time")] pub fn time(&self) -> ClockTime { unsafe { from_glib(ffi::gst_clock_id_get_time(self.to_glib_none().0)) } } + #[doc(alias = "gst_clock_id_unschedule")] pub fn unschedule(&self) { unsafe { ffi::gst_clock_id_unschedule(self.to_glib_none().0) } } + #[doc(alias = "gst_clock_id_wait")] pub fn wait(&self) -> (Result, ClockTimeDiff) { unsafe { let mut jitter = 0; @@ -63,12 +66,14 @@ impl ClockId { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_clock")] + #[doc(alias = "gst_clock_id_get_clock")] pub fn clock(&self) -> Option { unsafe { from_glib_full(ffi::gst_clock_id_get_clock(self.to_glib_none().0)) } } #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_clock_id_uses_clock")] pub fn uses_clock>(&self, clock: &P) -> bool { unsafe { from_glib(ffi::gst_clock_id_uses_clock( @@ -130,6 +135,7 @@ impl SingleShotClockId { self.0.compare_by_time(&other.0) } + #[doc(alias = "gst_clock_id_wait_async")] pub fn wait_async(&self, func: F) -> Result where F: FnOnce(&Clock, ClockTime, &ClockId) + Send + 'static, @@ -239,6 +245,7 @@ impl PeriodicClockId { self.0.compare_by_time(&other.0) } + #[doc(alias = "gst_clock_id_wait_async")] pub fn wait_async(&self, func: F) -> Result where F: Fn(&Clock, ClockTime, &ClockId) + Send + 'static, @@ -337,6 +344,7 @@ unsafe impl Send for ClockId {} unsafe impl Sync for ClockId {} impl Clock { + #[doc(alias = "gst_clock_adjust_with_calibration")] pub fn adjust_with_calibration( internal_target: ClockTime, cinternal: ClockTime, @@ -357,6 +365,7 @@ impl Clock { } } + #[doc(alias = "gst_clock_unadjust_with_calibration")] pub fn unadjust_with_calibration( external_target: ClockTime, cinternal: ClockTime, @@ -379,8 +388,10 @@ impl Clock { } pub trait ClockExtManual: 'static { + #[doc(alias = "gst_clock_new_periodic_id")] fn new_periodic_id(&self, start_time: ClockTime, interval: ClockTime) -> PeriodicClockId; + #[doc(alias = "gst_clock_periodic_id_reinit")] fn periodic_id_reinit( &self, id: &PeriodicClockId, @@ -388,8 +399,10 @@ pub trait ClockExtManual: 'static { interval: ClockTime, ) -> Result<(), glib::BoolError>; + #[doc(alias = "gst_clock_new_single_shot_id")] fn new_single_shot_id(&self, time: ClockTime) -> SingleShotClockId; + #[doc(alias = "gst_clock_single_shot_id_reinit")] fn single_shot_id_reinit( &self, id: &SingleShotClockId, diff --git a/gstreamer/src/context.rs b/gstreamer/src/context.rs index 158691b54..151bf4a89 100644 --- a/gstreamer/src/context.rs +++ b/gstreamer/src/context.rs @@ -12,6 +12,7 @@ mini_object_wrapper!(Context, ContextRef, ffi::GstContext, || { }); impl Context { + #[doc(alias = "gst_context_new")] pub fn new(context_type: &str, persistent: bool) -> Self { assert_initialized_main_thread!(); unsafe { @@ -25,6 +26,7 @@ impl Context { impl ContextRef { #[doc(alias = "get_context_type")] + #[doc(alias = "gst_context_get_context_type")] pub fn context_type(&self) -> &str { unsafe { let raw = ffi::gst_context_get_context_type(self.as_mut_ptr()); @@ -32,6 +34,7 @@ impl ContextRef { } } + #[doc(alias = "gst_context_has_context_type")] pub fn has_context_type(&self, context_type: &str) -> bool { unsafe { from_glib(ffi::gst_context_has_context_type( @@ -41,11 +44,13 @@ impl ContextRef { } } + #[doc(alias = "gst_context_is_persistent")] pub fn is_persistent(&self) -> bool { unsafe { from_glib(ffi::gst_context_is_persistent(self.as_mut_ptr())) } } #[doc(alias = "get_structure")] + #[doc(alias = "gst_context_get_structure")] pub fn structure(&self) -> &StructureRef { unsafe { StructureRef::from_glib_borrow(ffi::gst_context_get_structure(self.as_mut_ptr())) } } diff --git a/gstreamer/src/control_binding.rs b/gstreamer/src/control_binding.rs index b83c678d5..9160cfe21 100644 --- a/gstreamer/src/control_binding.rs +++ b/gstreamer/src/control_binding.rs @@ -7,6 +7,7 @@ use glib::translate::*; pub trait ControlBindingExtManual: 'static { #[doc(alias = "get_g_value_array")] + #[doc(alias = "gst_control_binding_get_g_value_array")] fn g_value_array( &self, timestamp: ClockTime, diff --git a/gstreamer/src/control_source.rs b/gstreamer/src/control_source.rs index 5416a1837..e5c77b2e4 100644 --- a/gstreamer/src/control_source.rs +++ b/gstreamer/src/control_source.rs @@ -7,6 +7,7 @@ use glib::translate::*; pub trait ControlSourceExtManual: 'static { #[doc(alias = "get_value_array")] + #[doc(alias = "gst_control_source_get_value_array")] fn value_array( &self, timestamp: ClockTime, diff --git a/gstreamer/src/date_time.rs b/gstreamer/src/date_time.rs index 46b425b8e..d94c5d7b2 100644 --- a/gstreamer/src/date_time.rs +++ b/gstreamer/src/date_time.rs @@ -108,6 +108,7 @@ fn validate( } impl DateTime { + #[doc(alias = "gst_date_time_new")] pub fn new< TZ: Into>, Y: Into, @@ -151,6 +152,7 @@ impl DateTime { } } + #[doc(alias = "gst_date_time_new_local_time")] pub fn new_local_time< Y: Into, MO: Into>, @@ -190,6 +192,7 @@ impl DateTime { } } + #[doc(alias = "gst_date_time_new_y")] pub fn new_y(year: i32) -> Result { assert_initialized_main_thread!(); @@ -201,6 +204,7 @@ impl DateTime { } } + #[doc(alias = "gst_date_time_new_ym")] pub fn new_ym(year: i32, month: i32) -> Result { assert_initialized_main_thread!(); @@ -212,6 +216,7 @@ impl DateTime { } } + #[doc(alias = "gst_date_time_new_ymd")] pub fn new_ymd(year: i32, month: i32, day: i32) -> Result { assert_initialized_main_thread!(); @@ -224,6 +229,7 @@ impl DateTime { } #[doc(alias = "get_day")] + #[doc(alias = "gst_date_time_get_day")] pub fn day(&self) -> Option { if !self.has_day() { return None; @@ -233,6 +239,7 @@ impl DateTime { } #[doc(alias = "get_hour")] + #[doc(alias = "gst_date_time_get_hour")] pub fn hour(&self) -> Option { if !self.has_time() { return None; @@ -242,6 +249,7 @@ impl DateTime { } #[doc(alias = "get_microsecond")] + #[doc(alias = "gst_date_time_get_microsecond")] pub fn microsecond(&self) -> Option { if !self.has_second() { return None; @@ -251,6 +259,7 @@ impl DateTime { } #[doc(alias = "get_minute")] + #[doc(alias = "gst_date_time_get_minute")] pub fn minute(&self) -> Option { if !self.has_time() { return None; @@ -260,6 +269,7 @@ impl DateTime { } #[doc(alias = "get_month")] + #[doc(alias = "gst_date_time_get_month")] pub fn month(&self) -> Option { if !self.has_month() { return None; @@ -269,6 +279,7 @@ impl DateTime { } #[doc(alias = "get_second")] + #[doc(alias = "gst_date_time_get_second")] pub fn second(&self) -> Option { if !self.has_second() { return None; @@ -278,6 +289,7 @@ impl DateTime { } #[doc(alias = "get_time_zone_offset")] + #[doc(alias = "gst_date_time_get_time_zone_offset")] pub fn time_zone_offset(&self) -> Option { if !self.has_time() { return None; diff --git a/gstreamer/src/device_monitor.rs b/gstreamer/src/device_monitor.rs index f4711760e..55cc313a9 100644 --- a/gstreamer/src/device_monitor.rs +++ b/gstreamer/src/device_monitor.rs @@ -9,6 +9,7 @@ use glib::translate::*; use std::num::NonZeroU32; impl DeviceMonitor { + #[doc(alias = "gst_device_monitor_new")] pub fn new() -> DeviceMonitor { assert_initialized_main_thread!(); let (major, minor, _, _) = crate::version(); @@ -47,12 +48,14 @@ impl FromGlib for DeviceMonitorFilterId { } pub trait DeviceMonitorExtManual: 'static { + #[doc(alias = "gst_device_monitor_add_filter")] fn add_filter( &self, classes: Option<&str>, caps: Option<&Caps>, ) -> Option; + #[doc(alias = "gst_device_monitor_remove_filter")] fn remove_filter(&self, filter_id: DeviceMonitorFilterId) -> Result<(), glib::error::BoolError>; } diff --git a/gstreamer/src/device_provider.rs b/gstreamer/src/device_provider.rs index e64220009..5743712d9 100644 --- a/gstreamer/src/device_provider.rs +++ b/gstreamer/src/device_provider.rs @@ -10,6 +10,7 @@ use glib::translate::*; use std::ffi::CStr; impl DeviceProvider { + #[doc(alias = "gst_device_provider_register")] pub fn register( plugin: Option<&Plugin>, name: &str, @@ -33,6 +34,7 @@ impl DeviceProvider { pub trait DeviceProviderExtManual: 'static { #[doc(alias = "get_metadata")] + #[doc(alias = "gst_device_provider_class_get_metadata")] fn metadata<'a>(&self, key: &str) -> Option<&'a str>; } diff --git a/gstreamer/src/element.rs b/gstreamer/src/element.rs index 51c1f199a..b322352a7 100644 --- a/gstreamer/src/element.rs +++ b/gstreamer/src/element.rs @@ -61,6 +61,7 @@ impl Element { } } + #[doc(alias = "gst_element_register")] pub fn register( plugin: Option<&Plugin>, name: &str, @@ -118,8 +119,10 @@ pub trait ElementExtManual: 'static { #[doc(alias = "get_pending_state")] fn pending_state(&self) -> State; + #[doc(alias = "gst_element_query")] fn query(&self, query: &mut QueryRef) -> bool; + #[doc(alias = "gst_element_send_event")] fn send_event(&self, event: Event) -> bool; #[doc(alias = "get_metadata")] @@ -131,6 +134,7 @@ pub trait ElementExtManual: 'static { fn pad_template_list(&self) -> Vec; #[allow(clippy::too_many_arguments)] + #[doc(alias = "gst_element_message_full")] fn message_full( &self, type_: ElementMessageType, @@ -152,6 +156,7 @@ pub trait ElementExtManual: 'static { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[allow(clippy::too_many_arguments)] + #[doc(alias = "gst_element_message_full_with_details")] fn message_full_with_details( &self, type_: ElementMessageType, @@ -164,11 +169,15 @@ pub trait ElementExtManual: 'static { structure: crate::Structure, ); + #[doc(alias = "gst_element_post_message")] fn post_message(&self, message: crate::Message) -> Result<(), glib::error::BoolError>; fn post_error_message(&self, msg: crate::ErrorMessage); + #[doc(alias = "gst_element_iterate_pads")] fn iterate_pads(&self) -> crate::Iterator; + #[doc(alias = "gst_element_iterate_sink_pads")] fn iterate_sink_pads(&self) -> crate::Iterator; + #[doc(alias = "gst_element_iterate_src_pads")] fn iterate_src_pads(&self) -> crate::Iterator; #[doc(alias = "get_pads")] @@ -184,6 +193,7 @@ pub trait ElementExtManual: 'static { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] + #[doc(alias = "gst_element_add_property_deep_notify_watch")] fn add_property_deep_notify_watch( &self, property_name: Option<&str>, @@ -192,6 +202,7 @@ pub trait ElementExtManual: 'static { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] + #[doc(alias = "gst_element_add_property_notify_watch")] fn add_property_notify_watch( &self, property_name: Option<&str>, @@ -200,8 +211,10 @@ pub trait ElementExtManual: 'static { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] + #[doc(alias = "gst_element_remove_property_notify_watch")] fn remove_property_notify_watch(&self, watch_id: NotifyWatchId); + #[doc(alias = "gst_element_query_convert")] fn query_convert, U: SpecificFormattedValue>( &self, src_val: V, @@ -212,12 +225,15 @@ pub trait ElementExtManual: 'static { dest_format: Format, ) -> Option; + #[doc(alias = "gst_element_query_duration")] fn query_duration(&self) -> Option; fn query_duration_generic(&self, format: Format) -> Option; + #[doc(alias = "gst_element_query_position")] fn query_position(&self) -> Option; fn query_position_generic(&self, format: Format) -> Option; + #[doc(alias = "gst_element_seek")] fn seek>( &self, rate: f64, @@ -227,6 +243,7 @@ pub trait ElementExtManual: 'static { stop_type: crate::SeekType, stop: V, ) -> Result<(), glib::error::BoolError>; + #[doc(alias = "gst_element_seek_simple")] fn seek_simple>( &self, seek_flags: crate::SeekFlags, @@ -235,6 +252,7 @@ pub trait ElementExtManual: 'static { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] + #[doc(alias = "gst_element_call_async")] fn call_async(&self, func: F) where F: FnOnce(&Self) + Send + 'static; @@ -773,6 +791,7 @@ impl> ElementExtManual for O { pub unsafe trait ElementClassExt { #[doc(alias = "get_metadata")] + #[doc(alias = "gst_element_class_get_metadata")] fn metadata<'a>(&self, key: &str) -> Option<&'a str> { unsafe { let klass = self as *const _ as *const ffi::GstElementClass; @@ -788,6 +807,7 @@ pub unsafe trait ElementClassExt { } #[doc(alias = "get_pad_template")] + #[doc(alias = "gst_element_class_get_pad_template")] fn pad_template(&self, name: &str) -> Option { unsafe { let klass = self as *const _ as *const ffi::GstElementClass; @@ -800,6 +820,7 @@ pub unsafe trait ElementClassExt { } #[doc(alias = "get_pad_template_list")] + #[doc(alias = "gst_element_class_get_pad_template_list")] fn pad_template_list(&self) -> Vec { unsafe { let klass = self as *const _ as *const ffi::GstElementClass; diff --git a/gstreamer/src/enums.rs b/gstreamer/src/enums.rs index a7e04ce6d..26de1237d 100644 --- a/gstreamer/src/enums.rs +++ b/gstreamer/src/enums.rs @@ -655,6 +655,7 @@ impl StateChange { } #[doc(alias = "get_name")] + #[doc(alias = "gst_state_change_get_name")] pub fn name<'a>(self) -> &'a str { cfg_if::cfg_if! { if #[cfg(feature = "v1_14")] { diff --git a/gstreamer/src/event.rs b/gstreamer/src/event.rs index 25bea4c91..cc6300ed7 100644 --- a/gstreamer/src/event.rs +++ b/gstreamer/src/event.rs @@ -24,6 +24,7 @@ use crate::EventType; pub struct Seqnum(pub(crate) NonZeroU32); impl Seqnum { + #[doc(alias = "gst_util_seqnum_next")] pub fn next() -> Self { unsafe { let v = ffi::gst_util_seqnum_next(); @@ -63,6 +64,7 @@ impl cmp::Ord for Seqnum { pub struct GroupId(pub(crate) NonZeroU32); impl GroupId { + #[doc(alias = "gst_util_group_id_next")] pub fn next() -> Self { unsafe { let v = ffi::gst_util_group_id_next(); @@ -135,6 +137,7 @@ mini_object_wrapper!(Event, EventRef, ffi::GstEvent, || { impl EventRef { #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_event_get_seqnum")] pub fn seqnum(&self) -> Seqnum { unsafe { let seqnum = ffi::gst_event_get_seqnum(self.as_mut_ptr()); @@ -144,15 +147,18 @@ impl EventRef { } #[doc(alias = "get_running_time_offset")] + #[doc(alias = "gst_event_get_running_time_offset")] pub fn running_time_offset(&self) -> i64 { unsafe { ffi::gst_event_get_running_time_offset(self.as_mut_ptr()) } } + #[doc(alias = "gst_event_set_running_time_offset")] pub fn set_running_time_offset(&mut self, offset: i64) { unsafe { ffi::gst_event_set_running_time_offset(self.as_mut_ptr(), offset) } } #[doc(alias = "get_structure")] + #[doc(alias = "gst_event_get_structure")] pub fn structure(&self) -> Option<&StructureRef> { unsafe { let structure = ffi::gst_event_get_structure(self.as_mut_ptr()); @@ -367,6 +373,7 @@ impl<'a> StreamStart<'a> { } #[doc(alias = "get_stream_flags")] + #[doc(alias = "gst_event_parse_stream_flags")] pub fn stream_flags(&self) -> crate::StreamFlags { unsafe { let mut stream_flags = mem::MaybeUninit::uninit(); @@ -378,6 +385,7 @@ impl<'a> StreamStart<'a> { } #[doc(alias = "get_group_id")] + #[doc(alias = "gst_event_parse_group_id")] pub fn group_id(&self) -> Option { unsafe { let mut group_id = mem::MaybeUninit::uninit(); @@ -396,6 +404,7 @@ impl<'a> StreamStart<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_stream")] + #[doc(alias = "gst_event_parse_stream")] pub fn stream(&self) -> Option { unsafe { let mut stream = ptr::null_mut(); @@ -419,6 +428,7 @@ impl<'a> Caps<'a> { } #[doc(alias = "get_caps")] + #[doc(alias = "gst_event_parse_caps")] pub fn caps(&self) -> &'a crate::CapsRef { unsafe { let mut caps = ptr::null_mut(); @@ -450,6 +460,7 @@ impl<'a> Segment<'a> { } #[doc(alias = "get_segment")] + #[doc(alias = "gst_event_parse_segment")] pub fn segment(&self) -> &'a crate::Segment { unsafe { let mut segment = ptr::null(); @@ -480,6 +491,7 @@ impl<'a> StreamCollection<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_stream_collection")] + #[doc(alias = "gst_event_parse_stream_collection")] pub fn stream_collection(&self) -> crate::StreamCollection { unsafe { let mut stream_collection = ptr::null_mut(); @@ -504,6 +516,7 @@ impl<'a> Tag<'a> { } #[doc(alias = "get_tag")] + #[doc(alias = "gst_event_parse_tag")] pub fn tag(&self) -> &'a crate::TagListRef { unsafe { let mut tags = ptr::null_mut(); @@ -577,6 +590,7 @@ impl<'a> SinkMessage<'a> { } #[doc(alias = "get_message")] + #[doc(alias = "gst_event_parse_sink_message")] pub fn message(&self) -> crate::Message { unsafe { let mut msg = ptr::null_mut(); @@ -650,6 +664,7 @@ impl<'a> Toc<'a> { } #[doc(alias = "get_toc")] + #[doc(alias = "gst_event_parse_toc")] pub fn toc(&self) -> (&'a crate::TocRef, bool) { unsafe { let mut toc = ptr::null_mut(); @@ -903,6 +918,7 @@ impl<'a> Seek<'a> { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_trickmode_interval")] + #[doc(alias = "gst_event_parse_seek_trickmode_interval")] pub fn trickmode_interval(&self) -> crate::ClockTime { unsafe { let mut trickmode_interval = mem::MaybeUninit::uninit(); @@ -945,6 +961,7 @@ impl<'a> Latency<'a> { } #[doc(alias = "get_latency")] + #[doc(alias = "gst_event_parse_latency")] pub fn latency(&self) -> crate::ClockTime { unsafe { let mut latency = mem::MaybeUninit::uninit(); @@ -1068,6 +1085,7 @@ impl<'a> SelectStreams<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_streams")] + #[doc(alias = "gst_event_parse_select_streams")] pub fn streams(&self) -> Vec { unsafe { let mut streams = ptr::null_mut(); diff --git a/gstreamer/src/functions.rs b/gstreamer/src/functions.rs index e413228ea..f7dbd2438 100644 --- a/gstreamer/src/functions.rs +++ b/gstreamer/src/functions.rs @@ -27,6 +27,7 @@ pub fn parse_bin_from_description_with_name( Ok(bin) } +#[doc(alias = "gst_parse_bin_from_description_full")] pub fn parse_bin_from_description_full( bin_description: &str, ghost_unlinked_pads: bool, @@ -70,6 +71,7 @@ pub fn parse_bin_from_description_with_name_full( Ok(bin) } +#[doc(alias = "gst_parse_launch_full")] pub fn parse_launch_full( pipeline_description: &str, mut context: Option<&mut ParseContext>, @@ -92,6 +94,7 @@ pub fn parse_launch_full( } } +#[doc(alias = "gst_parse_launchv_full")] pub fn parse_launchv_full( argv: &[&str], mut context: Option<&mut ParseContext>, @@ -116,6 +119,7 @@ pub fn parse_launchv_full( #[cfg(any(feature = "v1_12", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_12")))] +#[doc(alias = "gst_calculate_linear_regression")] pub fn calculate_linear_regression( xy: &[(u64, u64)], temp: Option<&mut [(u64, u64)]>, @@ -166,6 +170,7 @@ pub fn calculate_linear_regression( #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] +#[doc(alias = "gst_type_is_plugin_api")] pub fn type_is_plugin_api(type_: glib::types::Type) -> Option { assert_initialized_main_thread!(); unsafe { diff --git a/gstreamer/src/ghost_pad.rs b/gstreamer/src/ghost_pad.rs index 0a5ef1197..f11de1f07 100644 --- a/gstreamer/src/ghost_pad.rs +++ b/gstreamer/src/ghost_pad.rs @@ -15,6 +15,7 @@ use crate::StaticPadTemplate; use glib::translate::*; impl GhostPad { + #[doc(alias = "gst_ghost_pad_activate_mode_default")] pub fn activate_mode_default, Q: IsA>( pad: &P, parent: Option<&Q>, @@ -35,6 +36,7 @@ impl GhostPad { } } + #[doc(alias = "gst_ghost_pad_internal_activate_mode_default")] pub fn internal_activate_mode_default, Q: IsA>( pad: &P, parent: Option<&Q>, diff --git a/gstreamer/src/iterator.rs b/gstreamer/src/iterator.rs index 6bb9f60a7..814c2c1f9 100644 --- a/gstreamer/src/iterator.rs +++ b/gstreamer/src/iterator.rs @@ -39,6 +39,7 @@ where } #[allow(clippy::should_implement_trait)] + #[doc(alias = "gst_iterator_next")] pub fn next(&mut self) -> Result, IteratorError> { unsafe { let mut value = Value::uninitialized(); @@ -57,12 +58,14 @@ where } } + #[doc(alias = "gst_iterator_resync")] pub fn resync(&mut self) { unsafe { ffi::gst_iterator_resync(self.to_glib_none_mut().0); } } + #[doc(alias = "gst_iterator_filter")] pub fn filter(self, func: F) -> Self where F: Fn(T) -> bool + Send + Sync + 'static, @@ -84,6 +87,7 @@ where } } + #[doc(alias = "gst_iterator_find_custom")] pub fn find(&mut self, func: F) -> Option where F: FnMut(T) -> bool, @@ -108,6 +112,7 @@ where } } + #[doc(alias = "gst_iterator_foreach")] pub fn foreach(&mut self, func: F) -> Result<(), IteratorError> where F: FnMut(T), @@ -131,6 +136,7 @@ where } } + #[doc(alias = "gst_iterator_fold")] pub fn fold(&mut self, init: U, func: F) -> Result where F: FnMut(U, T) -> Result, @@ -167,6 +173,7 @@ impl Iterator where for<'a> T: FromValue<'a> + StaticType + ToValue + Send + 'static, { + #[doc(alias = "gst_iterator_new")] pub fn new>(imp: I) -> Self { assert_initialized_main_thread!(); static DUMMY_COOKIE: u32 = 0; diff --git a/gstreamer/src/lib.rs b/gstreamer/src/lib.rs index 11e07c3d6..1ed0a0008 100644 --- a/gstreamer/src/lib.rs +++ b/gstreamer/src/lib.rs @@ -232,6 +232,7 @@ pub use crate::functions::*; use std::ptr; +#[doc(alias = "gst_init_check")] pub fn init() -> Result<(), glib::Error> { unsafe { let mut error = ptr::null_mut(); diff --git a/gstreamer/src/log.rs b/gstreamer/src/log.rs index eb04a9b0c..61d2d3fc5 100644 --- a/gstreamer/src/log.rs +++ b/gstreamer/src/log.rs @@ -24,6 +24,7 @@ impl fmt::Debug for DebugMessage { } impl DebugMessage { + #[doc(alias = "gst_debug_message_get")] pub fn get(&self) -> Option> { unsafe { let message = ffi::gst_debug_message_get(self.0.as_ptr()); @@ -85,6 +86,7 @@ impl DebugCategory { } #[doc(alias = "get_threshold")] + #[doc(alias = "gst_debug_category_get_threshold")] pub fn threshold(self) -> crate::DebugLevel { match self.0 { Some(cat) => unsafe { from_glib(ffi::gst_debug_category_get_threshold(cat.as_ptr())) }, @@ -92,12 +94,14 @@ impl DebugCategory { } } + #[doc(alias = "gst_debug_category_set_threshold")] pub fn set_threshold(self, threshold: crate::DebugLevel) { if let Some(cat) = self.0 { unsafe { ffi::gst_debug_category_set_threshold(cat.as_ptr(), threshold.into_glib()) } } } + #[doc(alias = "gst_debug_category_reset_threshold")] pub fn reset_threshold(self) { if let Some(cat) = self.0 { unsafe { ffi::gst_debug_category_reset_threshold(cat.as_ptr()) } @@ -105,6 +109,7 @@ impl DebugCategory { } #[doc(alias = "get_color")] + #[doc(alias = "gst_debug_category_get_color")] pub fn color(self) -> crate::DebugColorFlags { match self.0 { Some(cat) => unsafe { from_glib(ffi::gst_debug_category_get_color(cat.as_ptr())) }, @@ -113,6 +118,7 @@ impl DebugCategory { } #[doc(alias = "get_name")] + #[doc(alias = "gst_debug_category_get_name")] pub fn name<'a>(self) -> &'a str { match self.0 { Some(cat) => unsafe { @@ -125,6 +131,7 @@ impl DebugCategory { } #[doc(alias = "get_description")] + #[doc(alias = "gst_debug_category_get_description")] pub fn description<'a>(self) -> Option<&'a str> { match self.0 { Some(cat) => unsafe { @@ -141,6 +148,7 @@ impl DebugCategory { } #[inline] + #[doc(alias = "gst_debug_log")] pub fn log>( self, obj: Option<&O>, @@ -456,6 +464,7 @@ impl fmt::Display for LoggedObject { } } +#[doc(alias = "gst_debug_add_log_function")] pub fn debug_add_log_function(function: T) -> DebugLogFunction where T: Fn(DebugCategory, DebugLevel, &str, &str, u32, Option<&LoggedObject>, &DebugMessage) @@ -483,6 +492,7 @@ pub fn debug_remove_default_log_function() { } } +#[doc(alias = "gst_debug_remove_log_function_by_data")] pub fn debug_remove_log_function(log_fn: DebugLogFunction) { skip_assert_initialized!(); unsafe { diff --git a/gstreamer/src/memory.rs b/gstreamer/src/memory.rs index d61ca6fbb..affa8dd49 100644 --- a/gstreamer/src/memory.rs +++ b/gstreamer/src/memory.rs @@ -225,6 +225,7 @@ impl MemoryRef { } } + #[doc(alias = "gst_memory_is_span")] pub fn is_span(&self, mem2: &MemoryRef) -> Option { unsafe { let mut offset = mem::MaybeUninit::uninit(); @@ -241,6 +242,7 @@ impl MemoryRef { } } + #[doc(alias = "gst_memory_is_type")] pub fn is_type(&self, mem_type: &str) -> bool { unsafe { from_glib(ffi::gst_memory_is_type( @@ -287,6 +289,7 @@ impl MemoryRef { } } + #[doc(alias = "gst_memory_share")] pub fn share(&self, offset: isize, size: Option) -> Memory { let pos_sz = match size { Some(val) => val as isize, @@ -305,6 +308,7 @@ impl MemoryRef { } } + #[doc(alias = "gst_memory_resize")] pub fn resize(&mut self, offset: isize, size: usize) { assert!(offset + (size as isize) < (self.maxsize() as isize)); unsafe { ffi::gst_memory_resize(self.as_mut_ptr(), offset, size) } diff --git a/gstreamer/src/message.rs b/gstreamer/src/message.rs index b4e0e9b3f..fbf947832 100644 --- a/gstreamer/src/message.rs +++ b/gstreamer/src/message.rs @@ -31,6 +31,7 @@ impl MessageRef { } #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_message_get_seqnum")] pub fn seqnum(&self) -> Seqnum { unsafe { let seqnum = ffi::gst_message_get_seqnum(self.as_mut_ptr()); @@ -55,6 +56,7 @@ impl MessageRef { } #[doc(alias = "get_structure")] + #[doc(alias = "gst_message_get_structure")] pub fn structure(&self) -> Option<&StructureRef> { unsafe { let structure = ffi::gst_message_get_structure(self.as_mut_ptr()); @@ -252,6 +254,7 @@ impl<'a> Error<'a> { } #[doc(alias = "get_error")] + #[doc(alias = "gst_message_parse_error")] pub fn error(&self) -> glib::Error { unsafe { let mut error = ptr::null_mut(); @@ -276,6 +279,7 @@ impl<'a> Error<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_details")] + #[doc(alias = "gst_message_parse_error_details")] pub fn details(&self) -> Option<&StructureRef> { unsafe { let mut details = ptr::null(); @@ -329,6 +333,7 @@ impl<'a> Warning<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_details")] + #[doc(alias = "gst_message_parse_error_details")] pub fn details(&self) -> Option<&StructureRef> { unsafe { let mut details = ptr::null(); @@ -382,6 +387,7 @@ impl<'a> Info<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_details")] + #[doc(alias = "gst_message_parse_error_details")] pub fn details(&self) -> Option<&StructureRef> { unsafe { let mut details = ptr::null(); @@ -443,6 +449,7 @@ impl<'a> Buffering<'a> { } #[doc(alias = "get_buffering_stats")] + #[doc(alias = "gst_message_parse_buffering_stats")] pub fn buffering_stats(&self) -> (crate::BufferingMode, i32, i32, i64) { unsafe { let mut mode = mem::MaybeUninit::uninit(); @@ -652,6 +659,7 @@ impl<'a> ClockProvide<'a> { } #[doc(alias = "get_clock")] + #[doc(alias = "gst_message_parse_clock_provide")] pub fn clock(&self) -> Option { let mut clock = ptr::null_mut(); @@ -692,6 +700,7 @@ impl<'a> ClockLost<'a> { } #[doc(alias = "get_clock")] + #[doc(alias = "gst_message_parse_clock_lost")] pub fn clock(&self) -> Option { let mut clock = ptr::null_mut(); @@ -717,6 +726,7 @@ impl<'a> NewClock<'a> { } #[doc(alias = "get_clock")] + #[doc(alias = "gst_message_parse_new_clock")] pub fn clock(&self) -> Option { let mut clock = ptr::null_mut(); @@ -792,6 +802,7 @@ impl<'a> StreamStatus<'a> { } #[doc(alias = "get_stream_status_object")] + #[doc(alias = "gst_message_get_stream_status_object")] pub fn stream_status_object(&self) -> Option { unsafe { let value = ffi::gst_message_get_stream_status_object(self.as_mut_ptr()); @@ -1100,6 +1111,7 @@ impl<'a> Qos<'a> { } #[doc(alias = "get_values")] + #[doc(alias = "gst_message_parse_qos_values")] pub fn values(&self) -> (i64, f64, i32) { unsafe { let mut jitter = mem::MaybeUninit::uninit(); @@ -1122,6 +1134,7 @@ impl<'a> Qos<'a> { } #[doc(alias = "get_stats")] + #[doc(alias = "gst_message_parse_qos_stats")] pub fn stats(&self) -> (GenericFormattedValue, GenericFormattedValue) { unsafe { let mut format = mem::MaybeUninit::uninit(); @@ -1203,6 +1216,7 @@ impl<'a> Toc<'a> { } #[doc(alias = "get_toc")] + #[doc(alias = "gst_message_parse_toc")] pub fn toc(&self) -> (crate::Toc, bool) { unsafe { let mut toc = ptr::null_mut(); @@ -1252,6 +1266,7 @@ impl<'a> StreamStart<'a> { } #[doc(alias = "get_group_id")] + #[doc(alias = "gst_message_parse_group_id")] pub fn group_id(&self) -> Option { unsafe { let mut group_id = mem::MaybeUninit::uninit(); @@ -1287,6 +1302,7 @@ impl<'a> NeedContext<'a> { } #[doc(alias = "get_context_type")] + #[doc(alias = "gst_message_parse_context_type")] pub fn context_type(&self) -> &str { unsafe { let mut context_type = ptr::null(); @@ -1312,6 +1328,7 @@ impl<'a> HaveContext<'a> { } #[doc(alias = "get_context")] + #[doc(alias = "gst_message_parse_have_context")] pub fn context(&self) -> crate::Context { unsafe { let mut context = ptr::null_mut(); @@ -1335,6 +1352,7 @@ impl<'a> DeviceAdded<'a> { } #[doc(alias = "get_device")] + #[doc(alias = "gst_message_parse_device_added")] pub fn device(&self) -> crate::Device { unsafe { let mut device = ptr::null_mut(); @@ -1360,6 +1378,7 @@ impl<'a> DeviceRemoved<'a> { } #[doc(alias = "get_device")] + #[doc(alias = "gst_message_parse_device_removed")] pub fn device(&self) -> crate::Device { unsafe { let mut device = ptr::null_mut(); @@ -1436,6 +1455,7 @@ impl<'a> StreamCollection<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_stream_collection")] + #[doc(alias = "gst_message_parse_stream_collection")] pub fn stream_collection(&self) -> crate::StreamCollection { unsafe { let mut collection = ptr::null_mut(); @@ -1480,6 +1500,8 @@ impl<'a> StreamsSelected<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_streams")] + #[doc(alias = "gst_message_streams_selected_get_size")] + #[doc(alias = "gst_message_streams_selected_get_stream")] pub fn streams(&self) -> Vec { unsafe { let n = ffi::gst_message_streams_selected_get_size(self.as_mut_ptr()); @@ -1516,6 +1538,7 @@ impl<'a> Redirect<'a> { #[cfg(any(feature = "v1_10", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_10")))] #[doc(alias = "get_entries")] + #[doc(alias = "gst_message_get_num_redirect_entries")] pub fn entries(&self) -> Vec<(&str, Option, Option<&StructureRef>)> { unsafe { let n = ffi::gst_message_get_num_redirect_entries(self.as_mut_ptr()); @@ -1574,6 +1597,7 @@ impl<'a> DeviceChanged<'a> { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_device_changed")] + #[doc(alias = "gst_message_parse_device_changed")] pub fn device_changed(&self) -> (crate::Device, crate::Device) { unsafe { let mut device = ptr::null_mut(); diff --git a/gstreamer/src/meta.rs b/gstreamer/src/meta.rs index e39e72a0a..452940a74 100644 --- a/gstreamer/src/meta.rs +++ b/gstreamer/src/meta.rs @@ -151,6 +151,7 @@ impl<'a, T: MetaAPI> MetaRef<'a, T> { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_meta_get_seqnum")] pub fn seqnum(&self) -> MetaSeqnum { unsafe { let meta = self.meta as *const _ as *const ffi::GstMeta; @@ -189,6 +190,7 @@ impl<'a, T: MetaAPI, U> MetaRefMut<'a, T, U> { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_seqnum")] + #[doc(alias = "gst_meta_get_seqnum")] pub fn seqnum(&self) -> u64 { unsafe { let meta = self.meta as *const _ as *const ffi::GstMeta; @@ -206,6 +208,7 @@ impl<'a, T: MetaAPI, U> MetaRefMut<'a, T, U> { } impl<'a, T: MetaAPI> MetaRefMut<'a, T, Standalone> { + #[doc(alias = "gst_buffer_remove_meta")] pub fn remove(mut self) { unsafe { let res = ffi::gst_buffer_remove_meta( @@ -264,6 +267,7 @@ unsafe impl Send for ParentBufferMeta {} unsafe impl Sync for ParentBufferMeta {} impl ParentBufferMeta { + #[doc(alias = "gst_buffer_add_parent_buffer_meta")] pub fn add<'a>(buffer: &'a mut BufferRef, parent: &Buffer) -> MetaRefMut<'a, Self, Standalone> { skip_assert_initialized!(); unsafe { @@ -290,6 +294,7 @@ impl ParentBufferMeta { unsafe impl MetaAPI for ParentBufferMeta { type GstType = ffi::GstParentBufferMeta; + #[doc(alias = "gst_parent_buffer_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_parent_buffer_meta_api_get_type()) } } @@ -310,6 +315,7 @@ unsafe impl Send for ProtectionMeta {} unsafe impl Sync for ProtectionMeta {} impl ProtectionMeta { + #[doc(alias = "gst_buffer_add_protection_meta")] pub fn add(buffer: &mut BufferRef, info: crate::Structure) -> MetaRefMut { skip_assert_initialized!(); unsafe { @@ -333,6 +339,7 @@ impl ProtectionMeta { unsafe impl MetaAPI for ProtectionMeta { type GstType = ffi::GstProtectionMeta; + #[doc(alias = "gst_protection_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_protection_meta_api_get_type()) } } @@ -361,6 +368,7 @@ unsafe impl Sync for ReferenceTimestampMeta {} #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] impl ReferenceTimestampMeta { + #[doc(alias = "gst_buffer_add_reference_timestamp_meta")] pub fn add<'a>( buffer: &'a mut BufferRef, reference: &Caps, @@ -406,6 +414,7 @@ impl ReferenceTimestampMeta { unsafe impl MetaAPI for ReferenceTimestampMeta { type GstType = ffi::GstReferenceTimestampMeta; + #[doc(alias = "gst_reference_timestamp_meta_api_get_type")] fn meta_api() -> glib::Type { unsafe { from_glib(ffi::gst_reference_timestamp_meta_api_get_type()) } } diff --git a/gstreamer/src/miniobject.rs b/gstreamer/src/miniobject.rs index 97677fc87..50e9878f1 100644 --- a/gstreamer/src/miniobject.rs +++ b/gstreamer/src/miniobject.rs @@ -69,6 +69,7 @@ macro_rules! mini_object_wrapper ( } } + #[doc(alias = "gst_mini_object_is_writable")] pub fn is_writable(&self) -> bool { unsafe { $crate::glib::translate::from_glib($crate::ffi::gst_mini_object_is_writable( @@ -383,6 +384,7 @@ macro_rules! mini_object_wrapper ( &mut *(ptr as *mut Self) } + #[doc(alias = "gst_mini_object_copy")] pub fn copy(&self) -> $name { unsafe { $name::from_glib_full($crate::ffi::gst_mini_object_copy( diff --git a/gstreamer/src/object.rs b/gstreamer/src/object.rs index bca269b44..5caf83466 100644 --- a/gstreamer/src/object.rs +++ b/gstreamer/src/object.rs @@ -22,6 +22,7 @@ pub trait GstObjectExtManual: 'static { fn object_flags(&self) -> ObjectFlags; #[doc(alias = "get_g_value_array")] + #[doc(alias = "gst_object_get_g_value_array")] fn g_value_array( &self, property_name: &str, diff --git a/gstreamer/src/pad.rs b/gstreamer/src/pad.rs index baae0d52f..a8c7c9d5e 100644 --- a/gstreamer/src/pad.rs +++ b/gstreamer/src/pad.rs @@ -89,17 +89,24 @@ pub enum PadGetRangeSuccess { } pub trait PadExtManual: 'static { + #[doc(alias = "gst_pad_add_probe")] fn add_probe(&self, mask: PadProbeType, func: F) -> Option where F: Fn(&Self, &mut PadProbeInfo) -> PadProbeReturn + Send + Sync + 'static; + #[doc(alias = "gst_pad_remove_probe")] fn remove_probe(&self, id: PadProbeId); + #[doc(alias = "gst_pad_chain")] fn chain(&self, buffer: Buffer) -> Result; + #[doc(alias = "gst_pad_push")] fn push(&self, buffer: Buffer) -> Result; + #[doc(alias = "gst_pad_chain_list")] fn chain_list(&self, list: BufferList) -> Result; + #[doc(alias = "gst_pad_push_list")] fn push_list(&self, list: BufferList) -> Result; + #[doc(alias = "gst_pad_pull_range")] fn pull_range(&self, offset: u64, size: u32) -> Result; fn pull_range_fill( &self, @@ -108,6 +115,7 @@ pub trait PadExtManual: 'static { size: u32, ) -> Result<(), FlowError>; #[doc(alias = "get_range")] + #[doc(alias = "gst_pad_get_range")] fn range(&self, offset: u64, size: u32) -> Result; #[doc(alias = "get_range_fill")] fn range_fill( @@ -117,21 +125,30 @@ pub trait PadExtManual: 'static { size: u32, ) -> Result<(), FlowError>; + #[doc(alias = "gst_pad_peer_query")] fn peer_query(&self, query: &mut QueryRef) -> bool; + #[doc(alias = "gst_pad_query")] fn query(&self, query: &mut QueryRef) -> bool; + #[doc(alias = "gst_pad_query_default")] fn query_default>( &self, parent: Option<&P>, query: &mut QueryRef, ) -> bool; fn proxy_query_caps(&self, query: &mut QueryRef) -> bool; + #[doc(alias = "gst_pad_proxy_query_accept_caps")] fn proxy_query_accept_caps(&self, query: &mut QueryRef) -> bool; + #[doc(alias = "gst_pad_event_default")] fn event_default>(&self, parent: Option<&P>, event: Event) -> bool; + #[doc(alias = "gst_pad_push_event")] fn push_event(&self, event: Event) -> bool; + #[doc(alias = "gst_pad_send_event")] fn send_event(&self, event: Event) -> bool; + #[doc(alias = "gst_pad_iterate_internal_links")] fn iterate_internal_links(&self) -> crate::Iterator; + #[doc(alias = "gst_pad_iterate_internal_links_default")] fn iterate_internal_links_default>( &self, parent: Option<&P>, @@ -211,8 +228,10 @@ pub trait PadExtManual: 'static { where F: Fn(&Self, Option<&crate::Object>) + Send + Sync + 'static; + #[doc(alias = "gst_pad_start_task")] fn start_task(&self, func: F) -> Result<(), glib::BoolError>; + #[doc(alias = "gst_pad_peer_query_convert")] fn peer_query_convert, U: SpecificFormattedValue>( &self, src_val: V, @@ -223,12 +242,15 @@ pub trait PadExtManual: 'static { dest_format: Format, ) -> Option; + #[doc(alias = "gst_pad_peer_query_duration")] fn peer_query_duration(&self) -> Option; fn peer_query_duration_generic(&self, format: Format) -> Option; + #[doc(alias = "gst_pad_peer_query_position")] fn peer_query_position(&self) -> Option; fn peer_query_position_generic(&self, format: Format) -> Option; + #[doc(alias = "gst_pad_query_convert")] fn query_convert, U: SpecificFormattedValue>( &self, src_val: V, @@ -239,15 +261,18 @@ pub trait PadExtManual: 'static { dest_format: Format, ) -> Option; + #[doc(alias = "gst_pad_query_duration")] fn query_duration(&self) -> Option; fn query_duration_generic(&self, format: Format) -> Option; + #[doc(alias = "gst_pad_query_position")] fn query_position(&self) -> Option; fn query_position_generic(&self, format: Format) -> Option; #[doc(alias = "get_mode")] fn mode(&self) -> crate::PadMode; + #[doc(alias = "gst_pad_sticky_events_foreach")] fn sticky_events_foreach Result, Option>>( &self, func: F, diff --git a/gstreamer/src/pad_template.rs b/gstreamer/src/pad_template.rs index d6d5baaa4..f8c6603bc 100644 --- a/gstreamer/src/pad_template.rs +++ b/gstreamer/src/pad_template.rs @@ -11,6 +11,7 @@ use glib::translate::*; impl PadTemplate { #[cfg(any(feature = "v1_14", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_14")))] + #[doc(alias = "gst_pad_template_new_from_static_pad_template_with_gtype")] pub fn from_static_pad_template_with_gtype( pad_template: &StaticPadTemplate, pad_type: glib::types::Type, diff --git a/gstreamer/src/parse_context.rs b/gstreamer/src/parse_context.rs index 575256652..ea4ffc3e5 100644 --- a/gstreamer/src/parse_context.rs +++ b/gstreamer/src/parse_context.rs @@ -25,11 +25,13 @@ unsafe impl Send for ParseContext {} unsafe impl Sync for ParseContext {} impl ParseContext { + #[doc(alias = "gst_parse_context_new")] pub fn new() -> Self { unsafe { from_glib_full(ffi::gst_parse_context_new()) } } #[doc(alias = "get_missing_elements")] + #[doc(alias = "gst_parse_context_get_missing_elements")] pub fn missing_elements(&self) -> Vec { unsafe { FromGlibPtrContainer::from_glib_full(ffi::gst_parse_context_get_missing_elements( diff --git a/gstreamer/src/plugin.rs b/gstreamer/src/plugin.rs index 8f30afaad..1364c6f5d 100644 --- a/gstreamer/src/plugin.rs +++ b/gstreamer/src/plugin.rs @@ -10,6 +10,7 @@ use glib::translate::*; impl Plugin { #[doc(alias = "get_cache_data")] + #[doc(alias = "gst_plugin_get_cache_data")] pub fn cache_data(&self) -> Option<&StructureRef> { unsafe { let cache_data = ffi::gst_plugin_get_cache_data(self.to_glib_none().0); @@ -21,6 +22,7 @@ impl Plugin { } } + #[doc(alias = "gst_plugin_set_cache_data")] pub fn set_cache_data(&self, cache_data: Structure) { unsafe { ffi::gst_plugin_set_cache_data(self.to_glib_none().0, cache_data.into_ptr()); diff --git a/gstreamer/src/plugin_feature.rs b/gstreamer/src/plugin_feature.rs index afb7f408c..e13f316fd 100644 --- a/gstreamer/src/plugin_feature.rs +++ b/gstreamer/src/plugin_feature.rs @@ -8,8 +8,11 @@ use glib::translate::{from_glib, FromGlibPtrFull, IntoGlib, ToGlibPtr}; pub trait PluginFeatureExtManual: Sized + 'static { #[doc(alias = "get_rank")] + #[doc(alias = "gst_plugin_feature_get_rank")] fn rank(&self) -> Rank; + #[doc(alias = "gst_plugin_feature_set_rank")] fn set_rank(&self, rank: Rank); + #[doc(alias = "gst_plugin_feature_load")] fn load(&self) -> Result; } diff --git a/gstreamer/src/promise.rs b/gstreamer/src/promise.rs index 4eaf2a093..f5bbfcb48 100644 --- a/gstreamer/src/promise.rs +++ b/gstreamer/src/promise.rs @@ -28,11 +28,13 @@ pub enum PromiseError { } impl Promise { + #[doc(alias = "gst_promise_new")] pub fn new() -> Promise { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_promise_new()) } } + #[doc(alias = "gst_promise_new_with_change_func")] pub fn with_change_func(func: F) -> Promise where F: FnOnce(Result, PromiseError>) + Send + 'static, @@ -93,12 +95,14 @@ impl Promise { (promise.clone(), PromiseFuture(promise, receiver)) } + #[doc(alias = "gst_promise_expire")] pub fn expire(&self) { unsafe { ffi::gst_promise_expire(self.to_glib_none().0); } } + #[doc(alias = "gst_promise_get_reply")] pub fn get_reply(&self) -> Option<&StructureRef> { unsafe { let s = ffi::gst_promise_get_reply(self.to_glib_none().0); @@ -110,12 +114,14 @@ impl Promise { } } + #[doc(alias = "gst_promise_interrupt")] pub fn interrupt(&self) { unsafe { ffi::gst_promise_interrupt(self.to_glib_none().0); } } + #[doc(alias = "gst_promise_reply")] pub fn reply(&self, s: Option) { unsafe { ffi::gst_promise_reply( @@ -125,6 +131,7 @@ impl Promise { } } + #[doc(alias = "gst_promise_wait")] pub fn wait(&self) -> PromiseResult { unsafe { from_glib(ffi::gst_promise_wait(self.to_glib_none().0)) } } diff --git a/gstreamer/src/proxy_pad.rs b/gstreamer/src/proxy_pad.rs index 4ab2cc8f6..e8b472112 100644 --- a/gstreamer/src/proxy_pad.rs +++ b/gstreamer/src/proxy_pad.rs @@ -13,18 +13,21 @@ use glib::prelude::*; use glib::translate::*; pub trait ProxyPadExtManual: 'static { + #[doc(alias = "gst_proxy_pad_chain_default")] fn chain_default>( &self, parent: Option<&P>, buffer: Buffer, ) -> Result; + #[doc(alias = "gst_proxy_pad_chain_list_default")] fn chain_list_default>( &self, parent: Option<&P>, list: BufferList, ) -> Result; + #[doc(alias = "gst_proxy_pad_getrange_default")] fn getrange_default>( &self, parent: Option<&P>, @@ -32,6 +35,7 @@ pub trait ProxyPadExtManual: 'static { size: u32, ) -> Result; + #[doc(alias = "gst_proxy_pad_iterate_internal_links_default")] fn iterate_internal_links_default>( &self, parent: Option<&P>, diff --git a/gstreamer/src/query.rs b/gstreamer/src/query.rs index 5373d4899..600caf36d 100644 --- a/gstreamer/src/query.rs +++ b/gstreamer/src/query.rs @@ -17,6 +17,7 @@ mini_object_wrapper!(Query, QueryRef, ffi::GstQuery, || { impl QueryRef { #[doc(alias = "get_structure")] + #[doc(alias = "gst_query_get_structure")] pub fn structure(&self) -> Option<&StructureRef> { unsafe { let structure = ffi::gst_query_get_structure(self.as_mut_ptr()); @@ -218,6 +219,7 @@ macro_rules! declare_concrete_query( declare_concrete_query!(Position, T); impl Position { + #[doc(alias = "gst_query_new_position")] pub fn new(fmt: crate::Format) -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_position(fmt.into_glib()))) } @@ -250,6 +252,7 @@ impl Position { } impl Position { + #[doc(alias = "gst_query_set_position")] pub fn set>(&mut self, pos: V) { let pos = pos.into(); assert_eq!(pos.format(), self.format()); @@ -261,6 +264,7 @@ impl Position { declare_concrete_query!(Duration, T); impl Duration { + #[doc(alias = "gst_query_new_duration")] pub fn new(fmt: crate::Format) -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_duration(fmt.into_glib()))) } @@ -293,6 +297,7 @@ impl Duration { } impl Duration { + #[doc(alias = "gst_query_set_duration")] pub fn set>(&mut self, dur: V) { let dur = dur.into(); assert_eq!(dur.format(), self.format()); @@ -304,6 +309,7 @@ impl Duration { declare_concrete_query!(Latency, T); impl Latency { + #[doc(alias = "gst_query_new_latency")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_latency())) } @@ -341,6 +347,7 @@ impl Latency { } impl Latency { + #[doc(alias = "gst_query_set_latency")] pub fn set(&mut self, live: bool, min: crate::ClockTime, max: crate::ClockTime) { unsafe { ffi::gst_query_set_latency( @@ -355,6 +362,7 @@ impl Latency { declare_concrete_query!(Seeking, T); impl Seeking { + #[doc(alias = "gst_query_new_seeking")] pub fn new(fmt: crate::Format) -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_seeking(fmt.into_glib()))) } @@ -403,6 +411,7 @@ impl Seeking { } impl Seeking { + #[doc(alias = "gst_query_set_seeking")] pub fn set>(&mut self, seekable: bool, start: V, end: V) { let start = start.into(); let end = end.into(); @@ -424,6 +433,7 @@ impl Seeking { declare_concrete_query!(Segment, T); impl Segment { + #[doc(alias = "gst_query_new_segment")] pub fn new(fmt: crate::Format) -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_segment(fmt.into_glib()))) } @@ -472,6 +482,7 @@ impl Segment { } impl Segment { + #[doc(alias = "gst_query_set_segment")] pub fn set>(&mut self, rate: f64, start: V, stop: V) { let start = start.into(); let stop = stop.into(); @@ -492,6 +503,7 @@ impl Segment { declare_concrete_query!(Convert, T); impl Convert { + #[doc(alias = "gst_query_new_convert")] pub fn new>(value: V, dest_fmt: crate::Format) -> Self { assert_initialized_main_thread!(); let value = value.into(); @@ -550,6 +562,7 @@ impl Convert { } impl Convert { + #[doc(alias = "gst_query_set_convert")] pub fn set>(&mut self, src: V, dest: V) { let src = src.into(); let dest = dest.into(); @@ -568,6 +581,7 @@ impl Convert { declare_concrete_query!(Formats, T); impl Formats { + #[doc(alias = "gst_query_new_formats")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_formats())) } @@ -601,6 +615,7 @@ impl Formats { } impl Formats { + #[doc(alias = "gst_query_set_formatsv")] pub fn set(&mut self, formats: &[crate::Format]) { unsafe { let v: Vec<_> = formats.iter().map(|f| f.into_glib()).collect(); @@ -611,6 +626,7 @@ impl Formats { declare_concrete_query!(Buffering, T); impl Buffering { + #[doc(alias = "gst_query_new_buffering")] pub fn new(fmt: crate::Format) -> Self { assert_initialized_main_thread!(); unsafe { @@ -640,6 +656,7 @@ impl Buffering { } #[doc(alias = "get_percent")] + #[doc(alias = "gst_query_parse_buffering_percent")] pub fn percent(&self) -> (bool, i32) { unsafe { let mut busy = mem::MaybeUninit::uninit(); @@ -656,6 +673,7 @@ impl Buffering { } #[doc(alias = "get_range")] + #[doc(alias = "gst_query_parse_buffering_range")] pub fn range(&self) -> (GenericFormattedValue, GenericFormattedValue, i64) { unsafe { let mut fmt = mem::MaybeUninit::uninit(); @@ -679,6 +697,7 @@ impl Buffering { } #[doc(alias = "get_stats")] + #[doc(alias = "gst_query_parse_buffering_stats")] pub fn stats(&self) -> (crate::BufferingMode, i32, i32, i64) { unsafe { let mut mode = mem::MaybeUninit::uninit(); @@ -704,6 +723,7 @@ impl Buffering { } #[doc(alias = "get_ranges")] + #[doc(alias = "gst_query_get_n_buffering_ranges")] pub fn ranges(&self) -> Vec<(GenericFormattedValue, GenericFormattedValue)> { unsafe { let mut fmt = mem::MaybeUninit::uninit(); @@ -813,6 +833,7 @@ impl Buffering { declare_concrete_query!(Custom, T); impl Custom { + #[doc(alias = "gst_query_new_custom")] pub fn new(structure: crate::Structure) -> Self { assert_initialized_main_thread!(); unsafe { @@ -826,6 +847,7 @@ impl Custom { declare_concrete_query!(Uri, T); impl Uri { + #[doc(alias = "gst_query_new_uri")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_uri())) } @@ -840,6 +862,7 @@ impl Default for Uri { impl Uri { #[doc(alias = "get_uri")] + #[doc(alias = "gst_query_parse_uri")] pub fn uri(&self) -> Option { unsafe { let mut uri = ptr::null_mut(); @@ -849,6 +872,8 @@ impl Uri { } #[doc(alias = "get_redirection")] + #[doc(alias = "gst_query_parse_uri_redirection")] + #[doc(alias = "gst_query_parse_uri_redirection_permanent")] pub fn redirection(&self) -> (Option, bool) { unsafe { let mut uri = ptr::null_mut(); @@ -862,6 +887,7 @@ impl Uri { } impl Uri { + #[doc(alias = "gst_query_set_uri")] pub fn set_uri<'b, U: Into<&'b str>>(&mut self, uri: U) { let uri = uri.into(); unsafe { @@ -883,6 +909,7 @@ impl Uri { declare_concrete_query!(Allocation, T); impl Allocation { + #[doc(alias = "gst_query_new_allocation")] pub fn new(caps: &crate::Caps, need_pool: bool) -> Self { assert_initialized_main_thread!(); unsafe { @@ -916,6 +943,7 @@ impl Allocation { } #[doc(alias = "get_allocation_pools")] + #[doc(alias = "gst_query_get_n_allocation_pools")] pub fn allocation_pools(&self) -> Vec<(Option, u32, u32, u32)> { unsafe { let n = ffi::gst_query_get_n_allocation_pools(self.0.as_ptr()); @@ -947,6 +975,7 @@ impl Allocation { } #[doc(alias = "get_allocation_metas")] + #[doc(alias = "gst_query_get_n_allocation_metas")] pub fn allocation_metas(&self) -> Vec<(glib::Type, Option<&crate::StructureRef>)> { unsafe { let n = ffi::gst_query_get_n_allocation_metas(self.0.as_ptr()); @@ -970,6 +999,7 @@ impl Allocation { } } + #[doc(alias = "gst_query_find_allocation_meta")] pub fn find_allocation_meta(&self) -> Option { unsafe { let mut idx = mem::MaybeUninit::uninit(); @@ -988,6 +1018,7 @@ impl Allocation { } impl Allocation { + #[doc(alias = "gst_query_add_allocation_pool")] pub fn add_allocation_pool( &mut self, pool: Option<&crate::BufferPool>, @@ -1006,6 +1037,7 @@ impl Allocation { } } + #[doc(alias = "gst_query_set_nth_allocation_pool")] pub fn set_nth_allocation_pool( &mut self, idx: u32, @@ -1026,12 +1058,14 @@ impl Allocation { } } + #[doc(alias = "gst_query_remove_nth_allocation_pool")] pub fn remove_nth_allocation_pool(&mut self, idx: u32) { unsafe { ffi::gst_query_remove_nth_allocation_pool(self.0.as_mut_ptr(), idx); } } + #[doc(alias = "gst_query_add_allocation_meta")] pub fn add_allocation_meta( &mut self, structure: Option<&crate::StructureRef>, @@ -1049,6 +1083,7 @@ impl Allocation { } } + #[doc(alias = "gst_query_remove_nth_allocation_meta")] pub fn remove_nth_allocation_meta(&mut self, idx: u32) { unsafe { ffi::gst_query_remove_nth_allocation_meta(self.0.as_mut_ptr(), idx); @@ -1058,6 +1093,7 @@ impl Allocation { declare_concrete_query!(Scheduling, T); impl Scheduling { + #[doc(alias = "gst_query_new_scheduling")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_scheduling())) } @@ -1071,6 +1107,7 @@ impl Default for Scheduling { } impl Scheduling { + #[doc(alias = "gst_query_has_scheduling_mode")] pub fn has_scheduling_mode(&self, mode: crate::PadMode) -> bool { unsafe { from_glib(ffi::gst_query_has_scheduling_mode( @@ -1080,6 +1117,7 @@ impl Scheduling { } } + #[doc(alias = "gst_query_has_scheduling_mode_with_flags")] pub fn has_scheduling_mode_with_flags( &self, mode: crate::PadMode, @@ -1096,6 +1134,7 @@ impl Scheduling { } #[doc(alias = "get_scheduling_modes")] + #[doc(alias = "gst_query_get_n_scheduling_modes")] pub fn scheduling_modes(&self) -> Vec { unsafe { let n = ffi::gst_query_get_n_scheduling_modes(self.0.as_ptr()); @@ -1146,6 +1185,7 @@ impl Scheduling { } } + #[doc(alias = "gst_query_set_scheduling")] pub fn set(&mut self, flags: crate::SchedulingFlags, minsize: i32, maxsize: i32, align: i32) { unsafe { ffi::gst_query_set_scheduling( @@ -1161,6 +1201,7 @@ impl Scheduling { declare_concrete_query!(AcceptCaps, T); impl AcceptCaps { + #[doc(alias = "gst_query_new_accept_caps")] pub fn new(caps: &crate::Caps) -> Self { assert_initialized_main_thread!(); unsafe { @@ -1173,6 +1214,7 @@ impl AcceptCaps { impl AcceptCaps { #[doc(alias = "get_caps")] + #[doc(alias = "gst_query_parse_accept_caps")] pub fn caps(&self) -> &crate::CapsRef { unsafe { let mut caps = ptr::null_mut(); @@ -1187,6 +1229,7 @@ impl AcceptCaps { } #[doc(alias = "get_result")] + #[doc(alias = "gst_query_parse_accept_caps_result")] pub fn result(&self) -> bool { unsafe { let mut accepted = mem::MaybeUninit::uninit(); @@ -1206,6 +1249,7 @@ impl AcceptCaps { declare_concrete_query!(Caps, T); impl Caps { + #[doc(alias = "gst_query_new_caps")] pub fn new(filter: Option<&crate::Caps>) -> Self { assert_initialized_main_thread!(); unsafe { @@ -1236,6 +1280,7 @@ impl Caps { } #[doc(alias = "get_result")] + #[doc(alias = "gst_query_parse_caps_result")] pub fn result(&self) -> Option<&crate::CapsRef> { unsafe { let mut caps = ptr::null_mut(); @@ -1264,6 +1309,7 @@ impl Caps { declare_concrete_query!(Drain, T); impl Drain { + #[doc(alias = "gst_query_new_drain")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_drain())) } @@ -1278,6 +1324,7 @@ impl Default for Drain { declare_concrete_query!(Context, T); impl Context { + #[doc(alias = "gst_query_new_context")] pub fn new(context_type: &str) -> Self { assert_initialized_main_thread!(); unsafe { @@ -1290,6 +1337,7 @@ impl Context { impl Context { #[doc(alias = "get_context")] + #[doc(alias = "gst_query_parse_context")] pub fn context(&self) -> Option<&crate::ContextRef> { unsafe { let mut context = ptr::null_mut(); @@ -1311,6 +1359,7 @@ impl Context { } #[doc(alias = "get_context_type")] + #[doc(alias = "gst_query_parse_context_type")] pub fn context_type(&self) -> &str { unsafe { let mut context_type = ptr::null(); @@ -1321,6 +1370,7 @@ impl Context { } impl Context { + #[doc(alias = "gst_query_set_context")] pub fn set_context(&mut self, context: &crate::Context) { unsafe { ffi::gst_query_set_context(self.0.as_mut_ptr(), context.as_mut_ptr()); @@ -1333,6 +1383,7 @@ declare_concrete_query!(Bitrate, T); #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] impl Bitrate { + #[doc(alias = "gst_query_new_bitrate")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { Self(from_glib_full(ffi::gst_query_new_bitrate())) } @@ -1351,6 +1402,7 @@ impl Bitrate { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] #[doc(alias = "get_bitrate")] + #[doc(alias = "gst_query_parse_bitrate")] pub fn bitrate(&self) -> u32 { unsafe { let mut bitrate = mem::MaybeUninit::uninit(); @@ -1363,6 +1415,7 @@ impl Bitrate { impl Bitrate { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_query_set_bitrate")] pub fn set_bitrate(&mut self, bitrate: u32) { unsafe { ffi::gst_query_set_bitrate(self.0.as_mut_ptr(), bitrate); diff --git a/gstreamer/src/sample.rs b/gstreamer/src/sample.rs index 202c15387..14175daf9 100644 --- a/gstreamer/src/sample.rs +++ b/gstreamer/src/sample.rs @@ -107,6 +107,7 @@ impl Sample { impl SampleRef { #[doc(alias = "get_buffer")] + #[doc(alias = "gst_sample_get_buffer")] pub fn buffer(&self) -> Option<&BufferRef> { unsafe { let ptr = ffi::gst_sample_get_buffer(self.as_mut_ptr()); @@ -124,6 +125,7 @@ impl SampleRef { } #[doc(alias = "get_buffer_list")] + #[doc(alias = "gst_sample_get_buffer_list")] pub fn buffer_list(&self) -> Option<&BufferListRef> { unsafe { let ptr = ffi::gst_sample_get_buffer_list(self.as_mut_ptr()); @@ -141,6 +143,7 @@ impl SampleRef { } #[doc(alias = "get_caps")] + #[doc(alias = "gst_sample_get_caps")] pub fn caps(&self) -> Option<&CapsRef> { unsafe { let ptr = ffi::gst_sample_get_caps(self.as_mut_ptr()); @@ -158,11 +161,13 @@ impl SampleRef { } #[doc(alias = "get_segment")] + #[doc(alias = "gst_sample_get_segment")] pub fn segment(&self) -> Option { unsafe { from_glib_none(ffi::gst_sample_get_segment(self.as_mut_ptr())) } } #[doc(alias = "get_info")] + #[doc(alias = "gst_sample_get_info")] pub fn info(&self) -> Option<&StructureRef> { unsafe { let ptr = ffi::gst_sample_get_info(self.as_mut_ptr()); @@ -176,30 +181,35 @@ impl SampleRef { #[cfg(any(feature = "v1_16", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_sample_set_buffer")] 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", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_sample_set_buffer_list")] 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", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_sample_set_caps")] 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", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_sample_set_segment")] 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", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_16")))] + #[doc(alias = "gst_sample_set_info")] pub fn set_info(&mut self, info: Option) { unsafe { ffi::gst_sample_set_info( diff --git a/gstreamer/src/segment.rs b/gstreamer/src/segment.rs index 7edd6229c..0939caeba 100644 --- a/gstreamer/src/segment.rs +++ b/gstreamer/src/segment.rs @@ -85,6 +85,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_clip")] pub fn clip>(&self, start: V, stop: V) -> Option<(T, T)> { let start = start.into(); let stop = stop.into(); @@ -117,6 +118,7 @@ impl FormattedSegment { } #[allow(clippy::too_many_arguments)] + #[doc(alias = "gst_segment_do_seek")] pub fn do_seek>( &mut self, rate: f64, @@ -156,6 +158,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_offset_running_time")] pub fn offset_running_time(&mut self, offset: i64) -> Result<(), glib::BoolError> { unsafe { glib::result_from_gboolean!( @@ -169,6 +172,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_position_from_running_time")] pub fn position_from_running_time>(&self, running_time: V) -> T { let running_time = running_time.into(); @@ -188,6 +192,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_position_from_running_time_full")] pub fn position_from_running_time_full>(&self, running_time: V) -> (i32, T) { let running_time = running_time.into(); @@ -210,6 +215,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_position_from_stream_time")] pub fn position_from_stream_time>(&self, stream_time: V) -> T { let stream_time = stream_time.into(); @@ -229,6 +235,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_position_from_stream_time_full")] pub fn position_from_stream_time_full>(&self, stream_time: V) -> (i32, T) { let stream_time = stream_time.into(); @@ -251,6 +258,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_set_running_time")] pub fn set_running_time>(&mut self, running_time: V) -> Result<(), glib::BoolError> { let running_time = running_time.into(); @@ -270,6 +278,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_to_running_time")] pub fn to_running_time>(&self, position: V) -> T { let position = position.into(); @@ -289,6 +298,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_to_running_time_full")] pub fn to_running_time_full>(&self, position: V) -> (i32, T) { let position = position.into(); @@ -311,6 +321,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_to_stream_time")] pub fn to_stream_time>(&self, position: V) -> T { let position = position.into(); @@ -330,6 +341,7 @@ impl FormattedSegment { } } + #[doc(alias = "gst_segment_to_stream_time_full")] pub fn to_stream_time_full>(&self, position: V) -> (i32, T) { let position = position.into(); @@ -496,6 +508,7 @@ impl FormattedSegment { impl PartialEq for FormattedSegment { #[inline] + #[doc(alias = "gst_segment_is_equal")] fn eq(&self, other: &Self) -> bool { unsafe { from_glib(ffi::gst_segment_is_equal(&self.0, &other.0)) } } diff --git a/gstreamer/src/static_caps.rs b/gstreamer/src/static_caps.rs index 6c9423446..86a5ea8eb 100644 --- a/gstreamer/src/static_caps.rs +++ b/gstreamer/src/static_caps.rs @@ -12,6 +12,7 @@ use std::ptr; pub struct StaticCaps(ptr::NonNull); impl StaticCaps { + #[doc(alias = "gst_static_caps_get")] pub fn get(&self) -> Caps { unsafe { from_glib_full(ffi::gst_static_caps_get(self.0.as_ptr())) } } diff --git a/gstreamer/src/static_pad_template.rs b/gstreamer/src/static_pad_template.rs index 1ec8249c0..c041c3223 100644 --- a/gstreamer/src/static_pad_template.rs +++ b/gstreamer/src/static_pad_template.rs @@ -13,11 +13,13 @@ use std::ptr; pub struct StaticPadTemplate(ptr::NonNull); impl StaticPadTemplate { + #[doc(alias = "gst_static_pad_template_get")] pub fn get(&self) -> PadTemplate { unsafe { from_glib_full(ffi::gst_static_pad_template_get(self.0.as_ptr())) } } #[doc(alias = "get_caps")] + #[doc(alias = "gst_static_pad_template_get_caps")] pub fn caps(&self) -> Caps { unsafe { from_glib_full(ffi::gst_static_pad_template_get_caps(self.0.as_ptr())) } } diff --git a/gstreamer/src/stream.rs b/gstreamer/src/stream.rs index f99b8b66c..8637c3cb3 100644 --- a/gstreamer/src/stream.rs +++ b/gstreamer/src/stream.rs @@ -8,6 +8,7 @@ use glib::translate::*; use std::fmt; impl Stream { + #[doc(alias = "gst_stream_new")] pub fn new( stream_id: Option<&str>, caps: Option<&Caps>, diff --git a/gstreamer/src/stream_collection.rs b/gstreamer/src/stream_collection.rs index b1bd7c1fa..cb3faa68b 100644 --- a/gstreamer/src/stream_collection.rs +++ b/gstreamer/src/stream_collection.rs @@ -65,6 +65,7 @@ impl<'a> ExactSizeIterator for Iter<'a> {} pub struct StreamCollectionBuilder(StreamCollection); impl StreamCollectionBuilder { + #[doc(alias = "gst_stream_collection_add_stream")] pub fn stream(self, stream: &Stream) -> Self { unsafe { ffi::gst_stream_collection_add_stream((self.0).to_glib_none().0, stream.to_glib_full()); diff --git a/gstreamer/src/structure.rs b/gstreamer/src/structure.rs index 3c422d4ba..cf73435da 100644 --- a/gstreamer/src/structure.rs +++ b/gstreamer/src/structure.rs @@ -72,6 +72,7 @@ impl Structure { Builder::new(name) } + #[doc(alias = "gst_structure_new_empty")] pub fn new_empty(name: &str) -> Structure { assert_initialized_main_thread!(); unsafe { @@ -187,6 +188,7 @@ impl Eq for Structure {} impl str::FromStr for Structure { type Err = glib::BoolError; + #[doc(alias = "gst_structure_from_string")] fn from_str(s: &str) -> Result { assert_initialized_main_thread!(); unsafe { @@ -460,6 +462,7 @@ impl StructureRef { } #[doc(alias = "get_name")] + #[doc(alias = "gst_structure_get_name")] pub fn name<'a>(&self) -> &'a str { unsafe { CStr::from_ptr(ffi::gst_structure_get_name(&self.0)) @@ -472,10 +475,12 @@ impl StructureRef { unsafe { from_glib(ffi::gst_structure_get_name_id(&self.0)) } } + #[doc(alias = "gst_structure_set_name")] pub fn set_name(&mut self, name: &str) { unsafe { ffi::gst_structure_set_name(&mut self.0, name.to_glib_none().0) } } + #[doc(alias = "gst_structure_has_field")] pub fn has_field(&self, field: &str) -> bool { unsafe { from_glib(ffi::gst_structure_has_field( @@ -509,6 +514,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_remove_field")] pub fn remove_field(&mut self, field: &str) { unsafe { ffi::gst_structure_remove_field(&mut self.0, field.to_glib_none().0); @@ -521,6 +527,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_remove_all_fields")] pub fn remove_all_fields(&mut self) { unsafe { ffi::gst_structure_remove_all_fields(&mut self.0); @@ -536,6 +543,7 @@ impl StructureRef { } #[doc(alias = "get_nth_field_name")] + #[doc(alias = "gst_structure_nth_field_name")] pub fn nth_field_name<'a>(&self, idx: u32) -> Option<&'a str> { unsafe { let field_name = ffi::gst_structure_nth_field_name(&self.0, idx); @@ -547,26 +555,32 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_n_fields")] pub fn n_fields(&self) -> u32 { unsafe { ffi::gst_structure_n_fields(&self.0) as u32 } } + #[doc(alias = "gst_structure_can_intersect")] pub fn can_intersect(&self, other: &StructureRef) -> bool { unsafe { from_glib(ffi::gst_structure_can_intersect(&self.0, &other.0)) } } + #[doc(alias = "gst_structure_intersect")] pub fn intersect(&self, other: &StructureRef) -> Option { unsafe { from_glib_full(ffi::gst_structure_intersect(&self.0, &other.0)) } } + #[doc(alias = "gst_structure_is_subset")] pub fn is_subset(&self, superset: &StructureRef) -> bool { unsafe { from_glib(ffi::gst_structure_is_subset(&self.0, &superset.0)) } } + #[doc(alias = "gst_structure_fixate")] pub fn fixate(&mut self) { unsafe { ffi::gst_structure_fixate(&mut self.0) } } + #[doc(alias = "gst_structure_fixate_field")] pub fn fixate_field(&mut self, name: &str) -> bool { unsafe { from_glib(ffi::gst_structure_fixate_field( @@ -576,6 +590,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_fixate_field_boolean")] pub fn fixate_field_bool(&mut self, name: &str, target: bool) -> bool { unsafe { from_glib(ffi::gst_structure_fixate_field_boolean( @@ -586,6 +601,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_fixate_field_string")] pub fn fixate_field_str(&mut self, name: &str, target: &str) -> bool { unsafe { from_glib(ffi::gst_structure_fixate_field_string( @@ -596,6 +612,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_fixate_field_nearest_double")] pub fn fixate_field_nearest_double(&mut self, name: &str, target: f64) -> bool { unsafe { from_glib(ffi::gst_structure_fixate_field_nearest_double( @@ -606,6 +623,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_fixate_field_nearest_fraction")] pub fn fixate_field_nearest_fraction>( &mut self, name: &str, @@ -624,6 +642,7 @@ impl StructureRef { } } + #[doc(alias = "gst_structure_fixate_field_nearest_int")] pub fn fixate_field_nearest_int(&mut self, name: &str, target: i32) -> bool { unsafe { from_glib(ffi::gst_structure_fixate_field_nearest_int( @@ -649,6 +668,7 @@ impl fmt::Debug for StructureRef { } impl PartialEq for StructureRef { + #[doc(alias = "gst_structure_is_equal")] fn eq(&self, other: &StructureRef) -> bool { unsafe { from_glib(ffi::gst_structure_is_equal(&self.0, &other.0)) } } diff --git a/gstreamer/src/tag_setter.rs b/gstreamer/src/tag_setter.rs index 7de2bdb61..b30d61605 100644 --- a/gstreamer/src/tag_setter.rs +++ b/gstreamer/src/tag_setter.rs @@ -7,6 +7,7 @@ use glib::prelude::*; use glib::translate::*; pub trait TagSetterExtManual: 'static { + #[doc(alias = "gst_tag_setter_add_tag_value")] fn add<'a, T: Tag<'a>>(&self, value: &T::TagType, mode: TagMergeMode); } diff --git a/gstreamer/src/tags.rs b/gstreamer/src/tags.rs index 1a1403724..9d0af9d2b 100644 --- a/gstreamer/src/tags.rs +++ b/gstreamer/src/tags.rs @@ -341,6 +341,7 @@ mini_object_wrapper!(TagList, TagListRef, ffi::GstTagList, || { }); impl TagList { + #[doc(alias = "gst_tag_list_new_empty")] pub fn new() -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_tag_list_new_empty()) } @@ -383,6 +384,7 @@ impl TagListRef { self.add_value(tag_name, &v, mode) } + #[doc(alias = "gst_tag_list_add_value")] pub fn add_value( &mut self, tag_name: &str, @@ -452,10 +454,12 @@ impl TagListRef { } } + #[doc(alias = "gst_tag_list_n_tags")] pub fn n_tags(&self) -> i32 { unsafe { ffi::gst_tag_list_n_tags(self.as_ptr()) } } + #[doc(alias = "gst_tag_list_nth_tag_name")] pub fn nth_tag_name(&self, idx: u32) -> &str { unsafe { CStr::from_ptr(ffi::gst_tag_list_nth_tag_name(self.as_ptr(), idx)) @@ -518,10 +522,12 @@ impl TagListRef { Iter::new(self) } + #[doc(alias = "gst_tag_list_insert")] pub fn insert(&mut self, other: &TagListRef, mode: TagMergeMode) { unsafe { ffi::gst_tag_list_insert(self.as_mut_ptr(), other.as_ptr(), mode.into_glib()) } } + #[doc(alias = "gst_tag_list_merge")] pub fn merge(&self, other: &TagListRef, mode: TagMergeMode) -> TagList { unsafe { from_glib_full(ffi::gst_tag_list_merge( @@ -533,10 +539,12 @@ impl TagListRef { } #[doc(alias = "get_scope")] + #[doc(alias = "gst_tag_list_get_scope")] pub fn scope(&self) -> TagScope { unsafe { from_glib(ffi::gst_tag_list_get_scope(self.as_ptr())) } } + #[doc(alias = "gst_tag_list_set_scope")] pub fn set_scope(&mut self, scope: TagScope) { unsafe { ffi::gst_tag_list_set_scope(self.as_mut_ptr(), scope.into_glib()) } } @@ -577,6 +585,7 @@ impl fmt::Display for TagListRef { } impl PartialEq for TagListRef { + #[doc(alias = "gst_tag_list_is_equal")] fn eq(&self, other: &TagListRef) -> bool { unsafe { from_glib(ffi::gst_tag_list_is_equal(self.as_ptr(), other.as_ptr())) } } @@ -831,16 +840,19 @@ impl<'a> DoubleEndedIterator for Iter<'a> { impl<'a> ExactSizeIterator for Iter<'a> {} +#[doc(alias = "gst_tag_exists")] pub fn tag_exists(name: &str) -> bool { skip_assert_initialized!(); unsafe { from_glib(ffi::gst_tag_exists(name.to_glib_none().0)) } } +#[doc(alias = "gst_tag_get_type")] pub fn tag_get_type(name: &str) -> glib::Type { skip_assert_initialized!(); unsafe { from_glib(ffi::gst_tag_get_type(name.to_glib_none().0)) } } +#[doc(alias = "gst_tag_get_nick")] pub fn tag_get_nick<'b>(name: &str) -> Option<&'b str> { skip_assert_initialized!(); unsafe { @@ -854,6 +866,7 @@ pub fn tag_get_nick<'b>(name: &str) -> Option<&'b str> { } } +#[doc(alias = "gst_tag_get_description")] pub fn tag_get_description<'b>(name: &str) -> Option<&'b str> { skip_assert_initialized!(); unsafe { @@ -867,6 +880,7 @@ pub fn tag_get_description<'b>(name: &str) -> Option<&'b str> { } } +#[doc(alias = "gst_tag_get_flag")] pub fn tag_get_flag(name: &str) -> crate::TagFlag { skip_assert_initialized!(); unsafe { from_glib(ffi::gst_tag_get_flag(name.to_glib_none().0)) } @@ -883,6 +897,7 @@ pub trait CustomTag<'a>: Tag<'a> { } } +#[doc(alias = "gst_tag_register")] pub fn register CustomTag<'a>>() { assert!(!tag_exists(T::tag_name())); @@ -905,6 +920,7 @@ pub fn register CustomTag<'a>>() { } } +#[doc(alias = "gst_tag_merge_use_first")] pub fn merge_use_first(src: &Value) -> Value { skip_assert_initialized!(); assert_eq!(src.type_(), crate::List::static_type()); @@ -918,6 +934,7 @@ pub fn merge_use_first(src: &Value) -> Value { } } +#[doc(alias = "gst_tag_merge_strings_with_comma")] pub fn merge_strings_with_comma(src: &Value) -> Value { skip_assert_initialized!(); assert_eq!(src.type_(), crate::List::static_type()); diff --git a/gstreamer/src/toc.rs b/gstreamer/src/toc.rs index 574f6db80..c8901036a 100644 --- a/gstreamer/src/toc.rs +++ b/gstreamer/src/toc.rs @@ -17,6 +17,7 @@ use crate::TocScope; mini_object_wrapper!(Toc, TocRef, ffi::GstToc, || { ffi::gst_toc_get_type() }); impl Toc { + #[doc(alias = "gst_toc_new")] pub fn new(scope: TocScope) -> Self { assert_initialized_main_thread!(); unsafe { from_glib_full(ffi::gst_toc_new(scope.into_glib())) } @@ -25,19 +26,23 @@ impl Toc { impl TocRef { #[doc(alias = "get_scope")] + #[doc(alias = "gst_toc_get_scope")] pub fn scope(&self) -> TocScope { unsafe { from_glib(ffi::gst_toc_get_scope(self.as_ptr())) } } + #[doc(alias = "gst_toc_find_entry")] pub fn find_entry(&self, uid: &str) -> Option { unsafe { from_glib_none(ffi::gst_toc_find_entry(self.as_ptr(), uid.to_glib_none().0)) } } #[doc(alias = "get_entries")] + #[doc(alias = "gst_toc_get_entries")] pub fn entries(&self) -> Vec { unsafe { FromGlibPtrContainer::from_glib_none(ffi::gst_toc_get_entries(self.as_ptr())) } } + #[doc(alias = "gst_toc_append_entry")] pub fn append_entry(&mut self, entry: TocEntry) { unsafe { ffi::gst_toc_append_entry(self.as_mut_ptr(), entry.into_ptr()); @@ -45,22 +50,26 @@ impl TocRef { } #[doc(alias = "get_tags")] + #[doc(alias = "gst_toc_get_tags")] pub fn tags(&self) -> Option { unsafe { from_glib_none(ffi::gst_toc_get_tags(self.as_ptr())) } } + #[doc(alias = "gst_toc_set_tags")] pub fn set_tags(&mut self, tag_list: TagList) { unsafe { ffi::gst_toc_set_tags(self.as_mut_ptr(), tag_list.into_ptr()); } } + #[doc(alias = "gst_toc_merge_tags")] pub fn merge_tags(&mut self, tag_list: &TagList, mode: TagMergeMode) { unsafe { ffi::gst_toc_merge_tags(self.as_mut_ptr(), tag_list.as_mut_ptr(), mode.into_glib()); } } + #[doc(alias = "gst_toc_dump")] pub fn dump(&self) { unsafe { ffi::gst_toc_dump(self.as_mut_ptr()); @@ -89,6 +98,7 @@ mini_object_wrapper!(TocEntry, TocEntryRef, ffi::GstTocEntry, || { }); impl TocEntry { + #[doc(alias = "gst_toc_entry_new")] pub fn new(type_: TocEntryType, uid: &str) -> Self { assert_initialized_main_thread!(); unsafe { @@ -102,11 +112,13 @@ impl TocEntry { impl TocEntryRef { #[doc(alias = "get_entry_type")] + #[doc(alias = "gst_toc_entry_get_entry_type")] pub fn entry_type(&self) -> TocEntryType { unsafe { from_glib(ffi::gst_toc_entry_get_entry_type(self.as_ptr())) } } #[doc(alias = "get_uid")] + #[doc(alias = "gst_toc_entry_get_uid")] pub fn uid(&self) -> &str { unsafe { CStr::from_ptr(ffi::gst_toc_entry_get_uid(self.as_ptr())) @@ -115,6 +127,7 @@ impl TocEntryRef { } } + #[doc(alias = "gst_toc_entry_append_sub_entry")] pub fn append_sub_entry(&mut self, subentry: TocEntry) { unsafe { ffi::gst_toc_entry_append_sub_entry(self.as_mut_ptr(), subentry.into_ptr()); @@ -122,6 +135,7 @@ impl TocEntryRef { } #[doc(alias = "get_sub_entries")] + #[doc(alias = "gst_toc_entry_get_sub_entries")] pub fn sub_entries(&self) -> Vec { unsafe { FromGlibPtrContainer::from_glib_none(ffi::gst_toc_entry_get_sub_entries(self.as_ptr())) @@ -129,11 +143,13 @@ impl TocEntryRef { } #[doc(alias = "get_parent")] + #[doc(alias = "gst_toc_entry_get_parent")] pub fn parent(&self) -> Option { unsafe { from_glib_none(ffi::gst_toc_entry_get_parent(self.as_mut_ptr())) } } #[doc(alias = "get_start_stop_times")] + #[doc(alias = "gst_toc_entry_get_start_stop_times")] pub fn start_stop_times(&self) -> Option<(i64, i64)> { unsafe { let mut start = mem::MaybeUninit::uninit(); @@ -151,6 +167,7 @@ impl TocEntryRef { } } + #[doc(alias = "gst_toc_entry_set_start_stop_times")] pub fn set_start_stop_times(&mut self, start: i64, stop: i64) { unsafe { ffi::gst_toc_entry_set_start_stop_times(self.as_mut_ptr(), start, stop); @@ -158,16 +175,19 @@ impl TocEntryRef { } #[doc(alias = "get_tags")] + #[doc(alias = "gst_toc_entry_get_tags")] pub fn tags(&self) -> Option { unsafe { from_glib_none(ffi::gst_toc_entry_get_tags(self.as_ptr())) } } + #[doc(alias = "gst_toc_entry_set_tags")] pub fn set_tags(&mut self, tag_list: TagList) { unsafe { ffi::gst_toc_entry_set_tags(self.as_mut_ptr(), tag_list.into_ptr()); } } + #[doc(alias = "gst_toc_entry_merge_tags")] pub fn merge_tags(&mut self, tag_list: &TagList, mode: TagMergeMode) { unsafe { ffi::gst_toc_entry_merge_tags( @@ -178,10 +198,12 @@ impl TocEntryRef { } } + #[doc(alias = "gst_toc_entry_is_alternative")] pub fn is_alternative(&self) -> bool { unsafe { from_glib(ffi::gst_toc_entry_is_alternative(self.as_ptr())) } } + #[doc(alias = "gst_toc_entry_is_sequence")] pub fn is_sequence(&self) -> bool { unsafe { from_glib(ffi::gst_toc_entry_is_sequence(self.as_ptr())) } } @@ -206,6 +228,7 @@ impl TocEntryRef { } } + #[doc(alias = "gst_toc_entry_set_loop")] pub fn set_loop(&mut self, loop_type: TocLoopType, repeat_count: i32) { unsafe { ffi::gst_toc_entry_set_loop(self.as_mut_ptr(), loop_type.into_glib(), repeat_count); diff --git a/gstreamer/src/typefind.rs b/gstreamer/src/typefind.rs index 950da2124..e0a62d41a 100644 --- a/gstreamer/src/typefind.rs +++ b/gstreamer/src/typefind.rs @@ -24,6 +24,7 @@ pub trait TypeFindImpl { } impl TypeFind { + #[doc(alias = "gst_type_find_register")] pub fn register( plugin: Option<&Plugin>, name: &str, @@ -55,6 +56,7 @@ impl TypeFind { } } + #[doc(alias = "gst_type_find_peek")] pub fn peek(&mut self, offset: i64, size: u32) -> Option<&[u8]> { unsafe { let data = ffi::gst_type_find_peek(&mut self.0, offset, size); @@ -66,6 +68,7 @@ impl TypeFind { } } + #[doc(alias = "gst_type_find_suggest")] pub fn suggest(&mut self, probability: TypeFindProbability, caps: &Caps) { unsafe { ffi::gst_type_find_suggest( @@ -77,6 +80,7 @@ impl TypeFind { } #[doc(alias = "get_length")] + #[doc(alias = "gst_type_find_get_length")] pub fn length(&mut self) -> Option { unsafe { let len = ffi::gst_type_find_get_length(&mut self.0); @@ -90,6 +94,7 @@ impl TypeFind { } impl TypeFindFactory { + #[doc(alias = "gst_type_find_factory_call_function")] pub fn call_function(&self, find: &mut dyn TypeFindImpl) { unsafe { let find_ptr = &find as *const &mut dyn TypeFindImpl as glib::ffi::gpointer; diff --git a/gstreamer/src/utils.rs b/gstreamer/src/utils.rs index 8aa113cfd..8ffc2afb3 100644 --- a/gstreamer/src/utils.rs +++ b/gstreamer/src/utils.rs @@ -7,6 +7,7 @@ pub struct MutexGuard<'a>(&'a glib::ffi::GMutex); impl<'a> MutexGuard<'a> { #[allow(clippy::trivially_copy_pass_by_ref)] + #[doc(alias = "g_mutex_lock")] pub fn lock(mutex: &'a glib::ffi::GMutex) -> Self { skip_assert_initialized!(); unsafe { diff --git a/gstreamer/src/value.rs b/gstreamer/src/value.rs index 85ffc5a24..761861763 100644 --- a/gstreamer/src/value.rs +++ b/gstreamer/src/value.rs @@ -810,19 +810,32 @@ impl<'a> glib::types::StaticType for List<'a> { } pub trait GstValueExt: Sized { + #[doc(alias = "gst_value_can_compare")] fn can_compare(&self, other: &Self) -> bool; + #[doc(alias = "gst_value_compare")] fn compare(&self, other: &Self) -> Option; fn eq(&self, other: &Self) -> bool; + #[doc(alias = "gst_value_can_intersect")] fn can_intersect(&self, other: &Self) -> bool; + #[doc(alias = "gst_value_intersect")] fn intersect(&self, other: &Self) -> Option; + #[doc(alias = "gst_value_can_subtract")] fn can_subtract(&self, other: &Self) -> bool; + #[doc(alias = "gst_value_subtract")] fn subtract(&self, other: &Self) -> Option; + #[doc(alias = "gst_value_can_union")] fn can_union(&self, other: &Self) -> bool; + #[doc(alias = "gst_value_union")] fn union(&self, other: &Self) -> Option; + #[doc(alias = "gst_value_fixate")] fn fixate(&self) -> Option; + #[doc(alias = "gst_value_is_fixed")] fn is_fixed(&self) -> bool; + #[doc(alias = "gst_value_is_subset")] fn is_subset(&self, superset: &Self) -> bool; + #[doc(alias = "gst_value_serialize")] fn serialize(&self) -> Result; + #[doc(alias = "gst_value_deserialize")] fn deserialize<'a, T: Into<&'a str>>(s: T) -> Result; }