Enum gstreamer_audio::StreamVolumeFormat [−][src]
pub enum StreamVolumeFormat { Linear, Cubic, Db, // some variants omitted }
Different representations of a stream volume. StreamVolume::convert_volume
allows to convert between the different representations.
Formulas to convert from a linear to a cubic or dB volume are cbrt(val) and 20 * log10 (val).
Variants
Linear
Cubic
Db
Trait Implementations
impl Debug for StreamVolumeFormat
[src]
impl Debug for StreamVolumeFormat
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Eq for StreamVolumeFormat
[src]
impl Eq for StreamVolumeFormat
impl PartialEq for StreamVolumeFormat
[src]
impl PartialEq for StreamVolumeFormat
fn eq(&self, other: &StreamVolumeFormat) -> bool
[src]
fn eq(&self, other: &StreamVolumeFormat) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &StreamVolumeFormat) -> bool
[src]
fn ne(&self, other: &StreamVolumeFormat) -> bool
This method tests for !=
.
impl Ord for StreamVolumeFormat
[src]
impl Ord for StreamVolumeFormat
fn cmp(&self, other: &StreamVolumeFormat) -> Ordering
[src]
fn cmp(&self, other: &StreamVolumeFormat) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl PartialOrd for StreamVolumeFormat
[src]
impl PartialOrd for StreamVolumeFormat
fn partial_cmp(&self, other: &StreamVolumeFormat) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &StreamVolumeFormat) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &StreamVolumeFormat) -> bool
[src]
fn lt(&self, other: &StreamVolumeFormat) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &StreamVolumeFormat) -> bool
[src]
fn le(&self, other: &StreamVolumeFormat) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &StreamVolumeFormat) -> bool
[src]
fn gt(&self, other: &StreamVolumeFormat) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &StreamVolumeFormat) -> bool
[src]
fn ge(&self, other: &StreamVolumeFormat) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Hash for StreamVolumeFormat
[src]
impl Hash for StreamVolumeFormat
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Clone for StreamVolumeFormat
[src]
impl Clone for StreamVolumeFormat
fn clone(&self) -> StreamVolumeFormat
[src]
fn clone(&self) -> StreamVolumeFormat
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for StreamVolumeFormat
[src]
impl Copy for StreamVolumeFormat
Auto Trait Implementations
impl Send for StreamVolumeFormat
impl Send for StreamVolumeFormat
impl Sync for StreamVolumeFormat
impl Sync for StreamVolumeFormat