[][src]Struct gstreamer_audio::AudioInfo

pub struct AudioInfo(_, _);

Information describing audio properties. This information can be filled in from GstCaps with AudioInfo::from_caps.

Use the provided macros to access the info in this structure.

Implementations

impl AudioInfo[src]

pub fn builder<'a>(
    format: AudioFormat,
    rate: u32,
    channels: u32
) -> AudioInfoBuilder<'a>
[src]

pub fn is_valid(&self) -> bool[src]

pub fn from_caps(caps: &CapsRef) -> Result<AudioInfo, BoolError>[src]

Parse caps and update self.

caps

a gst::Caps

Returns

TRUE if caps could be parsed

pub fn to_caps(&self) -> Result<Caps, BoolError>[src]

Convert the values of self into a gst::Caps.

Returns

the new gst::Caps containing the info of self.

pub fn convert<V: Into<GenericFormattedValue>, U: SpecificFormattedValue>(
    &self,
    src_val: V
) -> Option<U>
[src]

Converts among various gst::Format types. This function handles GST_FORMAT_BYTES, GST_FORMAT_TIME, and GST_FORMAT_DEFAULT. For raw audio, GST_FORMAT_DEFAULT corresponds to audio frames. This function can be used to handle pad queries of the type GST_QUERY_CONVERT.

src_fmt

gst::Format of the src_val

src_val

value to convert

dest_fmt

gst::Format of the dest_val

dest_val

pointer to destination value

Returns

TRUE if the conversion was successful.

pub fn convert_generic<V: Into<GenericFormattedValue>>(
    &self,
    src_val: V,
    dest_fmt: Format
) -> Option<GenericFormattedValue>
[src]

pub fn format(&self) -> AudioFormat[src]

pub fn format_info(&self) -> AudioFormatInfo[src]

pub fn layout(&self) -> AudioLayout[src]

pub fn flags(&self) -> AudioFlags[src]

pub fn rate(&self) -> u32[src]

pub fn channels(&self) -> u32[src]

pub fn bpf(&self) -> u32[src]

pub fn bps(&self) -> u32[src]

pub fn depth(&self) -> u32[src]

pub fn width(&self) -> u32[src]

pub fn endianness(&self) -> AudioEndianness[src]

pub fn is_big_endian(&self) -> bool[src]

pub fn is_little_endian(&self) -> bool[src]

pub fn is_float(&self) -> bool[src]

pub fn is_integer(&self) -> bool[src]

pub fn is_signed(&self) -> bool[src]

pub fn positions(&self) -> Option<&[AudioChannelPosition]>[src]

pub fn is_unpositioned(&self) -> bool[src]

Trait Implementations

impl Clone for AudioInfo[src]

impl Debug for AudioInfo[src]

impl Eq for AudioInfo[src]

impl PartialEq<AudioInfo> for AudioInfo[src]

impl Send for AudioInfo[src]

impl StaticType for AudioInfo[src]

impl Sync for AudioInfo[src]

Auto Trait Implementations

impl RefUnwindSafe for AudioInfo

impl Unpin for AudioInfo

impl UnwindSafe for AudioInfo

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToSendValue for T where
    T: ToValue + SetValue + Send + ?Sized
[src]

impl<T> ToValue for T where
    T: SetValue + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.