pub enum AudioError {
OpenError(Error),
UnsupportedFormat,
InvalidRange,
IoError(Error),
HoundError(Error),
ResampleError(ResampleError),
StreamError,
ShapeError(ShapeError),
InsufficientData(String),
InvalidInput(String),
ComputationFailed(String),
FileNotFound(String),
}Expand description
Enumerates error conditions for WAV-based audio operations.
Variants encapsulate specific failure modes encountered during file I/O, format parsing, or signal processing, with detailed diagnostics for DSP pipeline debugging.
Variants§
OpenError(Error)
WAV file open failure, typically due to invalid path or corrupted header.
UnsupportedFormat
Unsupported WAV sample format (only PCM 16-bit int and 32-bit float are supported).
InvalidRange
Offset or duration exceeds sample bounds.
IoError(Error)
General I/O error outside hound operations (e.g., filesystem issues).
HoundError(Error)
hound-specific error during sample read/write.
ResampleError(ResampleError)
Resampling failure from signal_processing::resampling.
StreamError
Streaming operation failure (e.g., channel disconnect).
ShapeError(ShapeError)
Array shape mismatch from ndarray operations.
InsufficientData(String)
Insufficient samples for requested operation.
InvalidInput(String)
Invalid parameter (e.g., negative offset).
ComputationFailed(String)
Numerical computation failure (e.g., overflow).
FileNotFound(String)
File not found at the specified path.
Trait Implementations§
Source§impl Debug for AudioError
impl Debug for AudioError
Source§impl Display for AudioError
impl Display for AudioError
Source§impl Error for AudioError
impl Error for AudioError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
Source§impl From<AudioError> for SpectralError
impl From<AudioError> for SpectralError
Source§fn from(source: AudioError) -> Self
fn from(source: AudioError) -> Self
Source§impl From<AudioError> for TimeDomainError
impl From<AudioError> for TimeDomainError
Source§fn from(source: AudioError) -> Self
fn from(source: AudioError) -> Self
Source§impl From<Error> for AudioError
impl From<Error> for AudioError
Source§impl From<Error> for AudioError
impl From<Error> for AudioError
Source§impl From<ResampleError> for AudioError
impl From<ResampleError> for AudioError
Source§fn from(source: ResampleError) -> Self
fn from(source: ResampleError) -> Self
Source§impl From<ShapeError> for AudioError
impl From<ShapeError> for AudioError
Source§fn from(source: ShapeError) -> Self
fn from(source: ShapeError) -> Self
Auto Trait Implementations§
impl Freeze for AudioError
impl !RefUnwindSafe for AudioError
impl Send for AudioError
impl Sync for AudioError
impl Unpin for AudioError
impl !UnwindSafe for AudioError
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more