forked from mirrors/gstreamer-rs
Regenerate everything with latest gir
This commit is contained in:
parent
606525b430
commit
bde6a04780
30 changed files with 191 additions and 123 deletions
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -122,15 +122,16 @@ impl Adapter {
|
|||
size: usize,
|
||||
) -> (isize, u32) {
|
||||
unsafe {
|
||||
let mut value = mem::uninitialized();
|
||||
let mut value = mem::MaybeUninit::uninit();
|
||||
let ret = gst_base_sys::gst_adapter_masked_scan_uint32_peek(
|
||||
self.to_glib_none().0,
|
||||
mask,
|
||||
pattern,
|
||||
offset,
|
||||
size,
|
||||
&mut value,
|
||||
value.as_mut_ptr(),
|
||||
);
|
||||
let value = value.assume_init();
|
||||
(ret, value)
|
||||
}
|
||||
}
|
||||
|
@ -142,23 +143,25 @@ impl Adapter {
|
|||
|
||||
pub fn prev_dts(&self) -> (gst::ClockTime, u64) {
|
||||
unsafe {
|
||||
let mut distance = mem::uninitialized();
|
||||
let mut distance = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_adapter_prev_dts(
|
||||
self.to_glib_none().0,
|
||||
&mut distance,
|
||||
distance.as_mut_ptr(),
|
||||
));
|
||||
let distance = distance.assume_init();
|
||||
(ret, distance)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn prev_dts_at_offset(&self, offset: usize) -> (gst::ClockTime, u64) {
|
||||
unsafe {
|
||||
let mut distance = mem::uninitialized();
|
||||
let mut distance = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_adapter_prev_dts_at_offset(
|
||||
self.to_glib_none().0,
|
||||
offset,
|
||||
&mut distance,
|
||||
distance.as_mut_ptr(),
|
||||
));
|
||||
let distance = distance.assume_init();
|
||||
(ret, distance)
|
||||
}
|
||||
}
|
||||
|
@ -166,31 +169,35 @@ impl Adapter {
|
|||
#[cfg(any(feature = "v1_10", feature = "dox"))]
|
||||
pub fn prev_offset(&self) -> (u64, u64) {
|
||||
unsafe {
|
||||
let mut distance = mem::uninitialized();
|
||||
let ret = gst_base_sys::gst_adapter_prev_offset(self.to_glib_none().0, &mut distance);
|
||||
let mut distance = mem::MaybeUninit::uninit();
|
||||
let ret =
|
||||
gst_base_sys::gst_adapter_prev_offset(self.to_glib_none().0, distance.as_mut_ptr());
|
||||
let distance = distance.assume_init();
|
||||
(ret, distance)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn prev_pts(&self) -> (gst::ClockTime, u64) {
|
||||
unsafe {
|
||||
let mut distance = mem::uninitialized();
|
||||
let mut distance = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_adapter_prev_pts(
|
||||
self.to_glib_none().0,
|
||||
&mut distance,
|
||||
distance.as_mut_ptr(),
|
||||
));
|
||||
let distance = distance.assume_init();
|
||||
(ret, distance)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn prev_pts_at_offset(&self, offset: usize) -> (gst::ClockTime, u64) {
|
||||
unsafe {
|
||||
let mut distance = mem::uninitialized();
|
||||
let mut distance = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_adapter_prev_pts_at_offset(
|
||||
self.to_glib_none().0,
|
||||
offset,
|
||||
&mut distance,
|
||||
distance.as_mut_ptr(),
|
||||
));
|
||||
let distance = distance.assume_init();
|
||||
(ret, distance)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -268,17 +268,21 @@ impl<O: IsA<BaseSink>> BaseSinkExt for O {
|
|||
|
||||
fn query_latency(&self) -> Option<(bool, bool, gst::ClockTime, gst::ClockTime)> {
|
||||
unsafe {
|
||||
let mut live = mem::uninitialized();
|
||||
let mut upstream_live = mem::uninitialized();
|
||||
let mut min_latency = mem::uninitialized();
|
||||
let mut max_latency = mem::uninitialized();
|
||||
let mut live = mem::MaybeUninit::uninit();
|
||||
let mut upstream_live = mem::MaybeUninit::uninit();
|
||||
let mut min_latency = mem::MaybeUninit::uninit();
|
||||
let mut max_latency = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_base_sink_query_latency(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut live,
|
||||
&mut upstream_live,
|
||||
&mut min_latency,
|
||||
&mut max_latency,
|
||||
live.as_mut_ptr(),
|
||||
upstream_live.as_mut_ptr(),
|
||||
min_latency.as_mut_ptr(),
|
||||
max_latency.as_mut_ptr(),
|
||||
));
|
||||
let live = live.assume_init();
|
||||
let upstream_live = upstream_live.assume_init();
|
||||
let min_latency = min_latency.assume_init();
|
||||
let max_latency = max_latency.assume_init();
|
||||
if ret {
|
||||
Some((
|
||||
from_glib(live),
|
||||
|
@ -392,12 +396,13 @@ impl<O: IsA<BaseSink>> BaseSinkExt for O {
|
|||
|
||||
fn wait_clock(&self, time: gst::ClockTime) -> (gst::ClockReturn, gst::ClockTimeDiff) {
|
||||
unsafe {
|
||||
let mut jitter = mem::uninitialized();
|
||||
let mut jitter = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_base_sink_wait_clock(
|
||||
self.as_ref().to_glib_none().0,
|
||||
time.to_glib(),
|
||||
&mut jitter,
|
||||
jitter.as_mut_ptr(),
|
||||
));
|
||||
let jitter = jitter.assume_init();
|
||||
(ret, jitter)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -147,15 +147,18 @@ impl<O: IsA<BaseSrc>> BaseSrcExt for O {
|
|||
|
||||
fn query_latency(&self) -> Option<(bool, gst::ClockTime, gst::ClockTime)> {
|
||||
unsafe {
|
||||
let mut live = mem::uninitialized();
|
||||
let mut min_latency = mem::uninitialized();
|
||||
let mut max_latency = mem::uninitialized();
|
||||
let mut live = mem::MaybeUninit::uninit();
|
||||
let mut min_latency = mem::MaybeUninit::uninit();
|
||||
let mut max_latency = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_base_sys::gst_base_src_query_latency(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut live,
|
||||
&mut min_latency,
|
||||
&mut max_latency,
|
||||
live.as_mut_ptr(),
|
||||
min_latency.as_mut_ptr(),
|
||||
max_latency.as_mut_ptr(),
|
||||
));
|
||||
let live = live.assume_init();
|
||||
let min_latency = min_latency.assume_init();
|
||||
let max_latency = max_latency.assume_init();
|
||||
if ret {
|
||||
Some((
|
||||
from_glib(live),
|
||||
|
|
|
@ -24,12 +24,13 @@ pub fn type_find_helper_for_buffer<P: IsA<gst::Object>>(
|
|||
) -> (Option<gst::Caps>, gst::TypeFindProbability) {
|
||||
assert_initialized_main_thread!();
|
||||
unsafe {
|
||||
let mut prob = mem::uninitialized();
|
||||
let mut prob = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib_full(gst_base_sys::gst_type_find_helper_for_buffer(
|
||||
obj.map(|p| p.as_ref()).to_glib_none().0,
|
||||
buf.to_glib_none().0,
|
||||
&mut prob,
|
||||
prob.as_mut_ptr(),
|
||||
));
|
||||
let prob = prob.assume_init();
|
||||
(ret, from_glib(prob))
|
||||
}
|
||||
}
|
||||
|
@ -42,15 +43,16 @@ pub fn type_find_helper_for_buffer_with_extension<P: IsA<gst::Object>>(
|
|||
) -> (Option<gst::Caps>, gst::TypeFindProbability) {
|
||||
assert_initialized_main_thread!();
|
||||
unsafe {
|
||||
let mut prob = mem::uninitialized();
|
||||
let mut prob = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib_full(
|
||||
gst_base_sys::gst_type_find_helper_for_buffer_with_extension(
|
||||
obj.map(|p| p.as_ref()).to_glib_none().0,
|
||||
buf.to_glib_none().0,
|
||||
extension.to_glib_none().0,
|
||||
&mut prob,
|
||||
prob.as_mut_ptr(),
|
||||
),
|
||||
);
|
||||
let prob = prob.assume_init();
|
||||
(ret, from_glib(prob))
|
||||
}
|
||||
}
|
||||
|
@ -64,14 +66,15 @@ pub fn type_find_helper_for_data_with_extension<P: IsA<gst::Object>>(
|
|||
assert_initialized_main_thread!();
|
||||
let size = data.len() as usize;
|
||||
unsafe {
|
||||
let mut prob = mem::uninitialized();
|
||||
let mut prob = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib_full(gst_base_sys::gst_type_find_helper_for_data_with_extension(
|
||||
obj.map(|p| p.as_ref()).to_glib_none().0,
|
||||
data.to_glib_none().0,
|
||||
size,
|
||||
extension.to_glib_none().0,
|
||||
&mut prob,
|
||||
prob.as_mut_ptr(),
|
||||
));
|
||||
let prob = prob.assume_init();
|
||||
(ret, from_glib(prob))
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -43,13 +43,15 @@ impl GLContext {
|
|||
pub fn get_current_gl_api(platform: GLPlatform) -> (GLAPI, u32, u32) {
|
||||
assert_initialized_main_thread!();
|
||||
unsafe {
|
||||
let mut major = mem::uninitialized();
|
||||
let mut minor = mem::uninitialized();
|
||||
let mut major = mem::MaybeUninit::uninit();
|
||||
let mut minor = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_gl_sys::gst_gl_context_get_current_gl_api(
|
||||
platform.to_glib(),
|
||||
&mut major,
|
||||
&mut minor,
|
||||
major.as_mut_ptr(),
|
||||
minor.as_mut_ptr(),
|
||||
));
|
||||
let major = major.assume_init();
|
||||
let minor = minor.assume_init();
|
||||
(ret, major, minor)
|
||||
}
|
||||
}
|
||||
|
@ -234,26 +236,30 @@ impl<O: IsA<GLContext>> GLContextExt for O {
|
|||
|
||||
fn get_gl_platform_version(&self) -> (i32, i32) {
|
||||
unsafe {
|
||||
let mut major = mem::uninitialized();
|
||||
let mut minor = mem::uninitialized();
|
||||
let mut major = mem::MaybeUninit::uninit();
|
||||
let mut minor = mem::MaybeUninit::uninit();
|
||||
gst_gl_sys::gst_gl_context_get_gl_platform_version(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut major,
|
||||
&mut minor,
|
||||
major.as_mut_ptr(),
|
||||
minor.as_mut_ptr(),
|
||||
);
|
||||
let major = major.assume_init();
|
||||
let minor = minor.assume_init();
|
||||
(major, minor)
|
||||
}
|
||||
}
|
||||
|
||||
fn get_gl_version(&self) -> (i32, i32) {
|
||||
unsafe {
|
||||
let mut maj = mem::uninitialized();
|
||||
let mut min = mem::uninitialized();
|
||||
let mut maj = mem::MaybeUninit::uninit();
|
||||
let mut min = mem::MaybeUninit::uninit();
|
||||
gst_gl_sys::gst_gl_context_get_gl_version(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut maj,
|
||||
&mut min,
|
||||
maj.as_mut_ptr(),
|
||||
min.as_mut_ptr(),
|
||||
);
|
||||
let maj = maj.assume_init();
|
||||
let min = min.assume_init();
|
||||
(maj, min)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -77,13 +77,15 @@ impl<O: IsA<GLFramebuffer>> GLFramebufferExt for O {
|
|||
|
||||
fn get_effective_dimensions(&self) -> (u32, u32) {
|
||||
unsafe {
|
||||
let mut width = mem::uninitialized();
|
||||
let mut height = mem::uninitialized();
|
||||
let mut width = mem::MaybeUninit::uninit();
|
||||
let mut height = mem::MaybeUninit::uninit();
|
||||
gst_gl_sys::gst_gl_framebuffer_get_effective_dimensions(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut width,
|
||||
&mut height,
|
||||
width.as_mut_ptr(),
|
||||
height.as_mut_ptr(),
|
||||
);
|
||||
let width = width.assume_init();
|
||||
let height = height.assume_init();
|
||||
(width, height)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -116,13 +116,15 @@ impl<O: IsA<GLWindow>> GLWindowExt for O {
|
|||
|
||||
fn get_surface_dimensions(&self) -> (u32, u32) {
|
||||
unsafe {
|
||||
let mut width = mem::uninitialized();
|
||||
let mut height = mem::uninitialized();
|
||||
let mut width = mem::MaybeUninit::uninit();
|
||||
let mut height = mem::MaybeUninit::uninit();
|
||||
gst_gl_sys::gst_gl_window_get_surface_dimensions(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut width,
|
||||
&mut height,
|
||||
width.as_mut_ptr(),
|
||||
height.as_mut_ptr(),
|
||||
);
|
||||
let width = width.assume_init();
|
||||
let height = height.assume_init();
|
||||
(width, height)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -56,11 +56,20 @@ pub fn pb_utils_get_source_description(protocol: &str) -> Option<GString> {
|
|||
pub fn plugins_base_version() -> (u32, u32, u32, u32) {
|
||||
assert_initialized_main_thread!();
|
||||
unsafe {
|
||||
let mut major = mem::uninitialized();
|
||||
let mut minor = mem::uninitialized();
|
||||
let mut micro = mem::uninitialized();
|
||||
let mut nano = mem::uninitialized();
|
||||
gst_pbutils_sys::gst_plugins_base_version(&mut major, &mut minor, &mut micro, &mut nano);
|
||||
let mut major = mem::MaybeUninit::uninit();
|
||||
let mut minor = mem::MaybeUninit::uninit();
|
||||
let mut micro = mem::MaybeUninit::uninit();
|
||||
let mut nano = mem::MaybeUninit::uninit();
|
||||
gst_pbutils_sys::gst_plugins_base_version(
|
||||
major.as_mut_ptr(),
|
||||
minor.as_mut_ptr(),
|
||||
micro.as_mut_ptr(),
|
||||
nano.as_mut_ptr(),
|
||||
);
|
||||
let major = major.assume_init();
|
||||
let minor = minor.assume_init();
|
||||
let micro = micro.assume_init();
|
||||
let nano = nano.assume_init();
|
||||
(major, minor, micro, nano)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -34,17 +34,21 @@ impl PlayerVideoOverlayVideoRenderer {
|
|||
|
||||
pub fn get_render_rectangle(&self) -> (i32, i32, i32, i32) {
|
||||
unsafe {
|
||||
let mut x = mem::uninitialized();
|
||||
let mut y = mem::uninitialized();
|
||||
let mut width = mem::uninitialized();
|
||||
let mut height = mem::uninitialized();
|
||||
let mut x = mem::MaybeUninit::uninit();
|
||||
let mut y = mem::MaybeUninit::uninit();
|
||||
let mut width = mem::MaybeUninit::uninit();
|
||||
let mut height = mem::MaybeUninit::uninit();
|
||||
gst_player_sys::gst_player_video_overlay_video_renderer_get_render_rectangle(
|
||||
self.to_glib_none().0,
|
||||
&mut x,
|
||||
&mut y,
|
||||
&mut width,
|
||||
&mut height,
|
||||
x.as_mut_ptr(),
|
||||
y.as_mut_ptr(),
|
||||
width.as_mut_ptr(),
|
||||
height.as_mut_ptr(),
|
||||
);
|
||||
let x = x.assume_init();
|
||||
let y = y.assume_init();
|
||||
let width = width.assume_init();
|
||||
let height = height.assume_init();
|
||||
(x, y, width, height)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -68,12 +68,13 @@ impl<O: IsA<RTSPMountPoints>> RTSPMountPointsExt for O {
|
|||
|
||||
fn match_(&self, path: &str) -> (RTSPMediaFactory, i32) {
|
||||
unsafe {
|
||||
let mut matched = mem::uninitialized();
|
||||
let mut matched = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib_full(gst_rtsp_server_sys::gst_rtsp_mount_points_match(
|
||||
self.as_ref().to_glib_none().0,
|
||||
path.to_glib_none().0,
|
||||
&mut matched,
|
||||
matched.as_mut_ptr(),
|
||||
));
|
||||
let matched = matched.assume_init();
|
||||
(ret, matched)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -154,12 +154,13 @@ impl<O: IsA<RTSPSession>> RTSPSessionExt for O {
|
|||
|
||||
fn get_media(&self, path: &str) -> (Option<RTSPSessionMedia>, i32) {
|
||||
unsafe {
|
||||
let mut matched = mem::uninitialized();
|
||||
let mut matched = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib_none(gst_rtsp_server_sys::gst_rtsp_session_get_media(
|
||||
self.as_ref().to_glib_none().0,
|
||||
path.to_glib_none().0,
|
||||
&mut matched,
|
||||
matched.as_mut_ptr(),
|
||||
));
|
||||
let matched = matched.assume_init();
|
||||
(ret, matched)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -111,12 +111,13 @@ impl<O: IsA<RTSPSessionMedia>> RTSPSessionMediaExt for O {
|
|||
|
||||
fn matches(&self, path: &str) -> Option<i32> {
|
||||
unsafe {
|
||||
let mut matched = mem::uninitialized();
|
||||
let mut matched = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_rtsp_server_sys::gst_rtsp_session_media_matches(
|
||||
self.as_ref().to_glib_none().0,
|
||||
path.to_glib_none().0,
|
||||
&mut matched,
|
||||
matched.as_mut_ptr(),
|
||||
));
|
||||
let matched = matched.assume_init();
|
||||
if ret {
|
||||
Some(matched)
|
||||
} else {
|
||||
|
|
|
@ -527,17 +527,21 @@ impl<O: IsA<RTSPStream>> RTSPStreamExt for O {
|
|||
|
||||
fn get_rtpinfo(&self) -> Option<(u32, u32, u32, gst::ClockTime)> {
|
||||
unsafe {
|
||||
let mut rtptime = mem::uninitialized();
|
||||
let mut seq = mem::uninitialized();
|
||||
let mut clock_rate = mem::uninitialized();
|
||||
let mut running_time = mem::uninitialized();
|
||||
let mut rtptime = mem::MaybeUninit::uninit();
|
||||
let mut seq = mem::MaybeUninit::uninit();
|
||||
let mut clock_rate = mem::MaybeUninit::uninit();
|
||||
let mut running_time = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_rtsp_server_sys::gst_rtsp_stream_get_rtpinfo(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut rtptime,
|
||||
&mut seq,
|
||||
&mut clock_rate,
|
||||
&mut running_time,
|
||||
rtptime.as_mut_ptr(),
|
||||
seq.as_mut_ptr(),
|
||||
clock_rate.as_mut_ptr(),
|
||||
running_time.as_mut_ptr(),
|
||||
));
|
||||
let rtptime = rtptime.assume_init();
|
||||
let seq = seq.assume_init();
|
||||
let clock_rate = clock_rate.assume_init();
|
||||
let running_time = running_time.assume_init();
|
||||
if ret {
|
||||
Some((rtptime, seq, clock_rate, from_glib(running_time)))
|
||||
} else {
|
||||
|
@ -584,11 +588,12 @@ impl<O: IsA<RTSPStream>> RTSPStreamExt for O {
|
|||
|
||||
fn get_ssrc(&self) -> u32 {
|
||||
unsafe {
|
||||
let mut ssrc = mem::uninitialized();
|
||||
let mut ssrc = mem::MaybeUninit::uninit();
|
||||
gst_rtsp_server_sys::gst_rtsp_stream_get_ssrc(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut ssrc,
|
||||
ssrc.as_mut_ptr(),
|
||||
);
|
||||
let ssrc = ssrc.assume_init();
|
||||
ssrc
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
|
@ -154,13 +154,14 @@ pub trait ClockExt: 'static {
|
|||
impl<O: IsA<Clock>> ClockExt for O {
|
||||
fn add_observation(&self, slave: ClockTime, master: ClockTime) -> Option<f64> {
|
||||
unsafe {
|
||||
let mut r_squared = mem::uninitialized();
|
||||
let mut r_squared = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_sys::gst_clock_add_observation(
|
||||
self.as_ref().to_glib_none().0,
|
||||
slave.to_glib(),
|
||||
master.to_glib(),
|
||||
&mut r_squared,
|
||||
r_squared.as_mut_ptr(),
|
||||
));
|
||||
let r_squared = r_squared.assume_init();
|
||||
if ret {
|
||||
Some(r_squared)
|
||||
} else {
|
||||
|
@ -175,21 +176,26 @@ impl<O: IsA<Clock>> ClockExt for O {
|
|||
master: ClockTime,
|
||||
) -> Option<(f64, ClockTime, ClockTime, ClockTime, ClockTime)> {
|
||||
unsafe {
|
||||
let mut r_squared = mem::uninitialized();
|
||||
let mut internal = mem::uninitialized();
|
||||
let mut external = mem::uninitialized();
|
||||
let mut rate_num = mem::uninitialized();
|
||||
let mut rate_denom = mem::uninitialized();
|
||||
let mut r_squared = mem::MaybeUninit::uninit();
|
||||
let mut internal = mem::MaybeUninit::uninit();
|
||||
let mut external = mem::MaybeUninit::uninit();
|
||||
let mut rate_num = mem::MaybeUninit::uninit();
|
||||
let mut rate_denom = mem::MaybeUninit::uninit();
|
||||
let ret = from_glib(gst_sys::gst_clock_add_observation_unapplied(
|
||||
self.as_ref().to_glib_none().0,
|
||||
slave.to_glib(),
|
||||
master.to_glib(),
|
||||
&mut r_squared,
|
||||
&mut internal,
|
||||
&mut external,
|
||||
&mut rate_num,
|
||||
&mut rate_denom,
|
||||
r_squared.as_mut_ptr(),
|
||||
internal.as_mut_ptr(),
|
||||
external.as_mut_ptr(),
|
||||
rate_num.as_mut_ptr(),
|
||||
rate_denom.as_mut_ptr(),
|
||||
));
|
||||
let r_squared = r_squared.assume_init();
|
||||
let internal = internal.assume_init();
|
||||
let external = external.assume_init();
|
||||
let rate_num = rate_num.assume_init();
|
||||
let rate_denom = rate_denom.assume_init();
|
||||
if ret {
|
||||
Some((
|
||||
r_squared,
|
||||
|
@ -215,17 +221,21 @@ impl<O: IsA<Clock>> ClockExt for O {
|
|||
|
||||
fn get_calibration(&self) -> (ClockTime, ClockTime, ClockTime, ClockTime) {
|
||||
unsafe {
|
||||
let mut internal = mem::uninitialized();
|
||||
let mut external = mem::uninitialized();
|
||||
let mut rate_num = mem::uninitialized();
|
||||
let mut rate_denom = mem::uninitialized();
|
||||
let mut internal = mem::MaybeUninit::uninit();
|
||||
let mut external = mem::MaybeUninit::uninit();
|
||||
let mut rate_num = mem::MaybeUninit::uninit();
|
||||
let mut rate_denom = mem::MaybeUninit::uninit();
|
||||
gst_sys::gst_clock_get_calibration(
|
||||
self.as_ref().to_glib_none().0,
|
||||
&mut internal,
|
||||
&mut external,
|
||||
&mut rate_num,
|
||||
&mut rate_denom,
|
||||
internal.as_mut_ptr(),
|
||||
external.as_mut_ptr(),
|
||||
rate_num.as_mut_ptr(),
|
||||
rate_denom.as_mut_ptr(),
|
||||
);
|
||||
let internal = internal.assume_init();
|
||||
let external = external.assume_init();
|
||||
let rate_num = rate_num.assume_init();
|
||||
let rate_denom = rate_denom.assume_init();
|
||||
(
|
||||
from_glib(internal),
|
||||
from_glib(external),
|
||||
|
|
|
@ -223,11 +223,20 @@ pub fn util_get_timestamp() -> ClockTime {
|
|||
pub fn version() -> (u32, u32, u32, u32) {
|
||||
assert_initialized_main_thread!();
|
||||
unsafe {
|
||||
let mut major = mem::uninitialized();
|
||||
let mut minor = mem::uninitialized();
|
||||
let mut micro = mem::uninitialized();
|
||||
let mut nano = mem::uninitialized();
|
||||
gst_sys::gst_version(&mut major, &mut minor, &mut micro, &mut nano);
|
||||
let mut major = mem::MaybeUninit::uninit();
|
||||
let mut minor = mem::MaybeUninit::uninit();
|
||||
let mut micro = mem::MaybeUninit::uninit();
|
||||
let mut nano = mem::MaybeUninit::uninit();
|
||||
gst_sys::gst_version(
|
||||
major.as_mut_ptr(),
|
||||
minor.as_mut_ptr(),
|
||||
micro.as_mut_ptr(),
|
||||
nano.as_mut_ptr(),
|
||||
);
|
||||
let major = major.assume_init();
|
||||
let minor = minor.assume_init();
|
||||
let micro = micro.assume_init();
|
||||
let nano = nano.assume_init();
|
||||
(major, minor, micro, nano)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Generated by gir (https://github.com/gtk-rs/gir @ 20feecf)
|
||||
Generated by gir (https://github.com/gtk-rs/gir @ fb0b31c)
|
||||
from gir-files (https://github.com/gtk-rs/gir-files @ ???)
|
||||
|
|
Loading…
Reference in a new issue