#[non_exhaustive]pub struct Decoded<S> {
pub samples: Vec<S>,
pub channels: Option<Channels>,
pub sample_rate: u32,
pub layer: u8,
pub avg_bitrate_kbps: u32,
pub format_changed: bool,
}Expand description
A decoded stream, from decode_all.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.samples: Vec<S>Interleaved samples, with the encoder delay and padding trimmed when the stream has a LAME/Lavc tag.
channels: Option<Channels>Channels of the stream; None if there was no audio, or the stream
switched between mono and stereo (see
Options::allow_mono_stereo_transition).
sample_rate: u32Sample rate in Hz (0 if there was no audio).
layer: u8MPEG layer (1, 2 or 3; 0 if there was no audio).
avg_bitrate_kbps: u32Average of the frame bitrates, in kbps.
format_changed: boolDecoding stopped early because the sample rate, layer or (unless
allowed) channel count changed; samples holds the audio before that.
Trait Implementations§
Auto Trait Implementations§
impl<S> Freeze for Decoded<S>
impl<S> RefUnwindSafe for Decoded<S>where
Vec<S>: RefUnwindSafe,
impl<S> Send for Decoded<S>
impl<S> Sync for Decoded<S>
impl<S> Unpin for Decoded<S>
impl<S> UnsafeUnpin for Decoded<S>where
Vec<S>: UnsafeUnpin,
impl<S> UnwindSafe for Decoded<S>where
Vec<S>: 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