[][src]Struct nannou_audio::buffer::Buffer

pub struct Buffer<S = f32> { /* fields omitted */ }

An interleaved PCM buffer yielded by either an input or output stream processing function.

Methods

impl<S> Buffer<S>[src]

pub const DEFAULT_LEN_FRAMES: usize[src]

The default number of frames per buffer.

This can be overridden by specifying your own buffer size using the stream::output::Builder::buffer_size builder method.

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

The sampling rate of the audio frames stored within the buffer.

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

The number of channels of audio per-frame within the buffer.

pub fn len_frames(&self) -> usize[src]

The length of the buffer as a number of audio frames (i.e. len / channels).

Important traits for Frames<'a, S>
pub fn frames(&self) -> Frames<S>[src]

Produce an iterator yielding each frame from the buffer in order.

Important traits for FramesMut<'a, S>
pub fn frames_mut(&mut self) -> FramesMut<S>[src]

Trait Implementations

impl<S: Debug> Debug for Buffer<S>[src]

impl<S> Deref for Buffer<S>[src]

type Target = [S]

The resulting type after dereferencing.

impl<S> DerefMut for Buffer<S>[src]

Auto Trait Implementations

impl<S> Sync for Buffer<S> where
    S: Sync

impl<S> Unpin for Buffer<S>

impl<S> Send for Buffer<S> where
    S: Send

impl<S> UnwindSafe for Buffer<S> where
    S: UnwindSafe

impl<S> RefUnwindSafe for Buffer<S> where
    S: RefUnwindSafe

Blanket Implementations

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

impl<T, U> Into<U> for T where
    U: From<T>, 
[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.

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

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

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

impl<S> FromSample<S> for S[src]

impl<T, U> ToSample<U> for T where
    U: FromSample<T>, 
[src]

impl<S, T> Duplex<S> for T where
    T: FromSample<S> + ToSample<S>, 
[src]