Trait gstreamer_audio::subclass::prelude::AudioSrcImpl

source ·
pub trait AudioSrcImpl: AudioSrcImplExt + AudioBaseSrcImpl {
    // Provided methods
    fn close(&self) -> Result<(), LoggableError> { ... }
    fn delay(&self) -> u32 { ... }
    fn open(&self) -> Result<(), LoggableError> { ... }
    fn prepare(
        &self,
        spec: &mut AudioRingBufferSpec,
    ) -> Result<(), LoggableError> { ... }
    fn unprepare(&self) -> Result<(), LoggableError> { ... }
    fn read(
        &self,
        audio_data: &mut [u8],
    ) -> Result<(u32, Option<ClockTime>), LoggableError> { ... }
    fn reset(&self) { ... }
}

Provided Methods§

source

fn close(&self) -> Result<(), LoggableError>

close the device

source

fn delay(&self) -> u32

the number of frames queued in the device

source

fn open(&self) -> Result<(), LoggableError>

open the device with the specified caps

source

fn prepare(&self, spec: &mut AudioRingBufferSpec) -> Result<(), LoggableError>

configure device with format

source

fn unprepare(&self) -> Result<(), LoggableError>

undo the configuration

source

fn read( &self, audio_data: &mut [u8], ) -> Result<(u32, Option<ClockTime>), LoggableError>

Read samples from the device.

§Returns
§timestamp

a GstClockTime

source

fn reset(&self)

unblock a read to the device and reset.

Object Safety§

This trait is not object safe.

Implementors§