pub enum AudioChunkError {
UnalignedSamples {
len: usize,
channels: u8,
},
ZeroChannels,
ZeroSampleRate,
}Expand description
Validation failure for AudioChunk::new.
Variants§
UnalignedSamples
Sample buffer length is not a multiple of the channel count. Each frame must carry one sample per channel.
ZeroChannels
Channel count is zero — not a meaningful format.
ZeroSampleRate
Sample rate is zero — not a meaningful format.
Trait Implementations§
Source§impl Debug for AudioChunkError
impl Debug for AudioChunkError
Source§impl Display for AudioChunkError
impl Display for AudioChunkError
Source§impl Error for AudioChunkError
impl Error for AudioChunkError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<AudioChunkError> for Error
impl From<AudioChunkError> for Error
Source§fn from(source: AudioChunkError) -> Self
fn from(source: AudioChunkError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for AudioChunkError
impl RefUnwindSafe for AudioChunkError
impl Send for AudioChunkError
impl Sync for AudioChunkError
impl Unpin for AudioChunkError
impl UnsafeUnpin for AudioChunkError
impl UnwindSafe for AudioChunkError
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