mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2025-01-09 00:35:41 +00:00
base: Remove duplicated setters/getters for basesink/basetransform properties
The functions are named non-standard and because of that can't be automatically ignored in favour of the properties.
This commit is contained in:
parent
849a524b09
commit
a21f334290
3 changed files with 39 additions and 89 deletions
|
@ -115,6 +115,36 @@ manual_traits = ["BaseSinkExtManual"]
|
|||
# Use Result
|
||||
manual = true
|
||||
|
||||
[[object.function]]
|
||||
name = "is_qos_enabled"
|
||||
# Same as the qos property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "set_qos_enabled"
|
||||
# Same as the qos property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "is_async_enabled"
|
||||
# Same as the async property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "set_async_enabled"
|
||||
# Same as the async property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "is_last_sample_enabled"
|
||||
# Same as the enable-last-sample property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "set_last_sample_enabled"
|
||||
# Same as the enable-last-sample property
|
||||
ignore = true
|
||||
|
||||
[[object]]
|
||||
name = "GstBase.BaseSrc"
|
||||
status = "generate"
|
||||
|
@ -150,6 +180,15 @@ manual_traits = ["BaseTransformExtManual"]
|
|||
[object.function.return]
|
||||
bool_return_is_error = "Failed to update src caps"
|
||||
|
||||
[[object.function]]
|
||||
name = "is_qos_enabled"
|
||||
# Same as the qos property
|
||||
ignore = true
|
||||
|
||||
[[object.function]]
|
||||
name = "set_qos_enabled"
|
||||
# Same as the qos property
|
||||
ignore = true
|
||||
|
||||
[[object]]
|
||||
name = "GstBase.Aggregator"
|
||||
|
|
|
@ -85,18 +85,6 @@ pub trait BaseSinkExt: 'static {
|
|||
#[doc(alias = "get_ts_offset")]
|
||||
fn ts_offset(&self) -> gst::ClockTimeDiff;
|
||||
|
||||
#[doc(alias = "gst_base_sink_is_async_enabled")]
|
||||
fn is_async_enabled(&self) -> bool;
|
||||
|
||||
#[doc(alias = "gst_base_sink_is_last_sample_enabled")]
|
||||
fn is_last_sample_enabled(&self) -> bool;
|
||||
|
||||
#[doc(alias = "gst_base_sink_is_qos_enabled")]
|
||||
fn is_qos_enabled(&self) -> bool;
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_async_enabled")]
|
||||
fn set_async_enabled(&self, enabled: bool);
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_blocksize")]
|
||||
fn set_blocksize(&self, blocksize: u32);
|
||||
|
||||
|
@ -105,9 +93,6 @@ pub trait BaseSinkExt: 'static {
|
|||
#[doc(alias = "gst_base_sink_set_drop_out_of_segment")]
|
||||
fn set_drop_out_of_segment(&self, drop_out_of_segment: bool);
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_last_sample_enabled")]
|
||||
fn set_last_sample_enabled(&self, enabled: bool);
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_max_bitrate")]
|
||||
fn set_max_bitrate(&self, max_bitrate: u64);
|
||||
|
||||
|
@ -119,9 +104,6 @@ pub trait BaseSinkExt: 'static {
|
|||
#[doc(alias = "gst_base_sink_set_processing_deadline")]
|
||||
fn set_processing_deadline(&self, processing_deadline: gst::ClockTime);
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_qos_enabled")]
|
||||
fn set_qos_enabled(&self, enabled: bool);
|
||||
|
||||
#[doc(alias = "gst_base_sink_set_render_delay")]
|
||||
fn set_render_delay(&self, delay: gst::ClockTime);
|
||||
|
||||
|
@ -318,39 +300,6 @@ impl<O: IsA<BaseSink>> BaseSinkExt for O {
|
|||
unsafe { ffi::gst_base_sink_get_ts_offset(self.as_ref().to_glib_none().0) }
|
||||
}
|
||||
|
||||
fn is_async_enabled(&self) -> bool {
|
||||
unsafe {
|
||||
from_glib(ffi::gst_base_sink_is_async_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
fn is_last_sample_enabled(&self) -> bool {
|
||||
unsafe {
|
||||
from_glib(ffi::gst_base_sink_is_last_sample_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
fn is_qos_enabled(&self) -> bool {
|
||||
unsafe {
|
||||
from_glib(ffi::gst_base_sink_is_qos_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
fn set_async_enabled(&self, enabled: bool) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_async_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
enabled.into_glib(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
fn set_blocksize(&self, blocksize: u32) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_blocksize(self.as_ref().to_glib_none().0, blocksize);
|
||||
|
@ -368,15 +317,6 @@ impl<O: IsA<BaseSink>> BaseSinkExt for O {
|
|||
}
|
||||
}
|
||||
|
||||
fn set_last_sample_enabled(&self, enabled: bool) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_last_sample_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
enabled.into_glib(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
fn set_max_bitrate(&self, max_bitrate: u64) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_max_bitrate(self.as_ref().to_glib_none().0, max_bitrate);
|
||||
|
@ -400,12 +340,6 @@ impl<O: IsA<BaseSink>> BaseSinkExt for O {
|
|||
}
|
||||
}
|
||||
|
||||
fn set_qos_enabled(&self, enabled: bool) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_qos_enabled(self.as_ref().to_glib_none().0, enabled.into_glib());
|
||||
}
|
||||
}
|
||||
|
||||
fn set_render_delay(&self, delay: gst::ClockTime) {
|
||||
unsafe {
|
||||
ffi::gst_base_sink_set_render_delay(self.as_ref().to_glib_none().0, delay.into_glib());
|
||||
|
|
|
@ -41,9 +41,6 @@ pub trait BaseTransformExt: 'static {
|
|||
#[doc(alias = "gst_base_transform_is_passthrough")]
|
||||
fn is_passthrough(&self) -> bool;
|
||||
|
||||
#[doc(alias = "gst_base_transform_is_qos_enabled")]
|
||||
fn is_qos_enabled(&self) -> bool;
|
||||
|
||||
#[cfg(any(feature = "v1_18", feature = "dox"))]
|
||||
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
|
||||
#[doc(alias = "gst_base_transform_reconfigure")]
|
||||
|
@ -67,9 +64,6 @@ pub trait BaseTransformExt: 'static {
|
|||
#[doc(alias = "gst_base_transform_set_prefer_passthrough")]
|
||||
fn set_prefer_passthrough(&self, prefer_passthrough: bool);
|
||||
|
||||
#[doc(alias = "gst_base_transform_set_qos_enabled")]
|
||||
fn set_qos_enabled(&self, enabled: bool);
|
||||
|
||||
#[doc(alias = "gst_base_transform_update_qos")]
|
||||
fn update_qos(&self, proportion: f64, diff: gst::ClockTimeDiff, timestamp: gst::ClockTime);
|
||||
|
||||
|
@ -113,14 +107,6 @@ impl<O: IsA<BaseTransform>> BaseTransformExt for O {
|
|||
}
|
||||
}
|
||||
|
||||
fn is_qos_enabled(&self) -> bool {
|
||||
unsafe {
|
||||
from_glib(ffi::gst_base_transform_is_qos_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(any(feature = "v1_18", feature = "dox"))]
|
||||
#[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))]
|
||||
fn reconfigure(&self) -> bool {
|
||||
|
@ -179,15 +165,6 @@ impl<O: IsA<BaseTransform>> BaseTransformExt for O {
|
|||
}
|
||||
}
|
||||
|
||||
fn set_qos_enabled(&self, enabled: bool) {
|
||||
unsafe {
|
||||
ffi::gst_base_transform_set_qos_enabled(
|
||||
self.as_ref().to_glib_none().0,
|
||||
enabled.into_glib(),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
fn update_qos(&self, proportion: f64, diff: gst::ClockTimeDiff, timestamp: gst::ClockTime) {
|
||||
unsafe {
|
||||
ffi::gst_base_transform_update_qos(
|
||||
|
|
Loading…
Reference in a new issue