gstreamer_video::prelude

Trait ColorBalanceExt

Source
pub trait ColorBalanceExt: IsA<ColorBalance> + 'static {
    // Provided methods
    fn balance_type(&self) -> ColorBalanceType { ... }
    fn value(&self, channel: &impl IsA<ColorBalanceChannel>) -> i32 { ... }
    fn list_channels(&self) -> Vec<ColorBalanceChannel> { ... }
    fn set_value(&self, channel: &impl IsA<ColorBalanceChannel>, value: i32) { ... }
    fn value_changed(&self, channel: &impl IsA<ColorBalanceChannel>, value: i32) { ... }
    fn connect_value_changed<F: Fn(&Self, &ColorBalanceChannel, i32) + Send + Sync + 'static>(
        &self,
        f: F,
    ) -> SignalHandlerId { ... }
}
Expand description

Trait containing all ColorBalance methods.

§Implementors

ColorBalance

Provided Methods§

Source

fn balance_type(&self) -> ColorBalanceType

Get the ColorBalanceType of this implementation.

§Returns

A the ColorBalanceType.

Source

fn value(&self, channel: &impl IsA<ColorBalanceChannel>) -> i32

Retrieve the current value of the indicated channel, between min_value and max_value.

See Also: The GstColorBalanceChannel.min_value and GstColorBalanceChannel.max_value members of the ColorBalanceChannel object.

§channel

A ColorBalanceChannel instance

§Returns

The current value of the channel.

Source

fn list_channels(&self) -> Vec<ColorBalanceChannel>

Retrieve a list of the available channels.

§Returns

A GList containing pointers to ColorBalanceChannel objects. The list is owned by the ColorBalance instance and must not be freed.

Source

fn set_value(&self, channel: &impl IsA<ColorBalanceChannel>, value: i32)

Sets the current value of the channel to the passed value, which must be between min_value and max_value.

See Also: The GstColorBalanceChannel.min_value and GstColorBalanceChannel.max_value members of the ColorBalanceChannel object.

§channel

A ColorBalanceChannel instance

§value

The new value for the channel.

Source

fn value_changed(&self, channel: &impl IsA<ColorBalanceChannel>, value: i32)

A helper function called by implementations of the GstColorBalance interface. It fires the value-changed signal on the instance, and the value-changed signal on the channel object.

§channel

A ColorBalanceChannel whose value has changed

§value

The new value of the channel

Source

fn connect_value_changed<F: Fn(&Self, &ColorBalanceChannel, i32) + Send + Sync + 'static>( &self, f: F, ) -> SignalHandlerId

Fired when the value of the indicated channel has changed.

§channel

The ColorBalanceChannel

§value

The new value

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§