pub struct AacDecoder { /* private fields */ }Expand description
ADTS AAC-LC decoder.
Implementations§
Source§impl AacDecoder
impl AacDecoder
pub fn new() -> Result<Self, &'static str>
Sourcepub fn frame_info(&self, data: &[u8]) -> Option<DecFrameInfo>
pub fn frame_info(&self, data: &[u8]) -> Option<DecFrameInfo>
Parse one frame header; None if data does not start with a valid frame sync.
Sourcepub fn decode_frame(
&mut self,
data: &[u8],
) -> Result<(Vec<f32>, DecFrameInfo), &'static str>
pub fn decode_frame( &mut self, data: &[u8], ) -> Result<(Vec<f32>, DecFrameInfo), &'static str>
Decode ONE frame at data[0]. Returns interleaved f32 PCM (empty while an MP3 reservoir fills) and the frame info.
Trait Implementations§
Source§impl Drop for AacDecoder
impl Drop for AacDecoder
impl Send for AacDecoder
Auto Trait Implementations§
impl !Sync for AacDecoder
impl Freeze for AacDecoder
impl RefUnwindSafe for AacDecoder
impl Unpin for AacDecoder
impl UnsafeUnpin for AacDecoder
impl UnwindSafe for AacDecoder
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