pub struct FrameReblocker { /* private fields */ }Expand description
Fixed-capacity ring-buffered frame reblocker slicing arbitrary normalized chunks into exact
block_frames blocks for CspaMixer with 0 heap allocations in steady state.
Implementations§
Source§impl FrameReblocker
impl FrameReblocker
pub fn new( channels: usize, block_frames: usize, max_buffered_frames: usize, ) -> Result<FrameReblocker, Reason>
pub fn channels(&self) -> usize
pub fn block_frames(&self) -> usize
pub fn buffered_frames(&self) -> usize
pub fn clear(&mut self)
pub fn push_samples(&mut self, samples: &[f32]) -> Result<(), Reason>
pub fn pop_block_into( &mut self, out_samples: &mut [f32], ) -> Result<bool, Reason>
pub fn peek_into( &self, frame_offset: usize, out_samples: &mut [f32], ) -> Result<bool, Reason>
pub fn discard_frames(&mut self, frames: usize) -> usize
Auto Trait Implementations§
impl Freeze for FrameReblocker
impl RefUnwindSafe for FrameReblocker
impl Send for FrameReblocker
impl Sync for FrameReblocker
impl Unpin for FrameReblocker
impl UnsafeUnpin for FrameReblocker
impl UnwindSafe for FrameReblocker
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