Struct audio::wrap::Sequential
source · pub struct Sequential<T> { /* private fields */ }
Expand description
A wrapper for a sequential audio buffer.
See wrap::sequential.
Implementations§
source§impl<T> Sequential<T>where
T: Slice,
impl<T> Sequential<T>where
T: Slice,
sourcepub fn into_inner(self) -> T
pub fn into_inner(self) -> T
Convert back into the wrapped value.
Examples
let buf = audio::wrap::sequential(&[1, 2, 3, 4], 2);
assert_eq!(buf.into_inner(), &[1, 2, 3, 4]);
source§impl<T> Sequential<T>where
T: SliceMut,
impl<T> Sequential<T>where
T: SliceMut,
sourcepub fn iter_mut(&mut self) -> IterChannelsMut<'_, T::Item> ⓘ
pub fn iter_mut(&mut self) -> IterChannelsMut<'_, T::Item> ⓘ
Construct an iterator over all sequential channels.
Trait Implementations§
source§impl<T> Buf for Sequential<T>where
T: Slice,
impl<T> Buf for Sequential<T>where
T: Slice,
§type Channel<'this> = LinearChannel<'this, <Sequential<T> as Buf>::Sample>
where
Self: 'this
type Channel<'this> = LinearChannel<'this, <Sequential<T> as Buf>::Sample> where Self: 'this
The type of the channel container.
§type IterChannels<'this> = IterChannels<'this, <Sequential<T> as Buf>::Sample>
where
Self: 'this
type IterChannels<'this> = IterChannels<'this, <Sequential<T> as Buf>::Sample> where Self: 'this
An iterator over available channels.
source§fn frames_hint(&self) -> Option<usize>
fn frames_hint(&self) -> Option<usize>
A typical number of frames for each channel in the buffer, if known. Read more
source§fn get_channel(&self, channel: usize) -> Option<Self::Channel<'_>>
fn get_channel(&self, channel: usize) -> Option<Self::Channel<'_>>
Return a handler to the buffer associated with the channel. Read more
source§fn iter_channels(&self) -> Self::IterChannels<'_>
fn iter_channels(&self) -> Self::IterChannels<'_>
Construct an iterator over all the channels in the audio buffer. Read more
source§fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
Construct a wrapper around this buffer that skips the first
n
frames. Read moresource§impl<T> BufMut for Sequential<T>where
T: SliceMut,
impl<T> BufMut for Sequential<T>where
T: SliceMut,
§type ChannelMut<'a> = LinearChannelMut<'a, <Sequential<T> as Buf>::Sample>
where
Self: 'a
type ChannelMut<'a> = LinearChannelMut<'a, <Sequential<T> as Buf>::Sample> where Self: 'a
The type of the mutable channel container.
§type IterChannelsMut<'a> = IterChannelsMut<'a, <Sequential<T> as Buf>::Sample>
where
Self: 'a
type IterChannelsMut<'a> = IterChannelsMut<'a, <Sequential<T> as Buf>::Sample> where Self: 'a
A mutable iterator over available channels.
source§fn get_channel_mut(&mut self, channel: usize) -> Option<Self::ChannelMut<'_>>
fn get_channel_mut(&mut self, channel: usize) -> Option<Self::ChannelMut<'_>>
Return a mutable handler to the buffer associated with the channel. Read more
source§fn iter_channels_mut(&mut self) -> Self::IterChannelsMut<'_>
fn iter_channels_mut(&mut self) -> Self::IterChannelsMut<'_>
Construct a mutable iterator over available channels. Read more
source§impl<T> ExactSizeBuf for Sequential<T>where
T: Slice,
impl<T> ExactSizeBuf for Sequential<T>where
T: Slice,
source§impl<T> UniformBuf for Sequential<T>where
T: Slice,
impl<T> UniformBuf for Sequential<T>where
T: Slice,
§type Frame<'this> = SequentialFrame<'this, <T as Slice>::Item>
where
Self: 'this
type Frame<'this> = SequentialFrame<'this, <T as Slice>::Item> where Self: 'this
The type the channel assumes when coerced into a reference.
§type IterFrames<'this> = SequentialFramesIter<'this, <T as Slice>::Item>
where
Self: 'this
type IterFrames<'this> = SequentialFramesIter<'this, <T as Slice>::Item> where Self: 'this
A borrowing iterator over the channel.
source§fn get_frame(&self, frame: usize) -> Option<Self::Frame<'_>>
fn get_frame(&self, frame: usize) -> Option<Self::Frame<'_>>
Get a single frame at the given offset. Read more
source§fn iter_frames(&self) -> Self::IterFrames<'_>
fn iter_frames(&self) -> Self::IterFrames<'_>
Construct an iterator over all the frames in the audio buffer. Read more
Auto Trait Implementations§
impl<T> RefUnwindSafe for Sequential<T>where
T: RefUnwindSafe,
impl<T> Send for Sequential<T>where
T: Send,
impl<T> Sync for Sequential<T>where
T: Sync,
impl<T> Unpin for Sequential<T>where
T: Unpin,
impl<T> UnwindSafe for Sequential<T>where
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more