use crate::signal::common::{FormatDecoder, INVALID_SAMPLE};
use crate::{Result, Sample};
use std::io::BufRead;
#[derive(Debug, Clone, Default)]
pub struct Format0Decoder;
impl Format0Decoder {
#[must_use]
pub const fn new() -> Self {
Self
}
}
impl FormatDecoder for Format0Decoder {
fn decode_buf(&mut self, _reader: &mut dyn BufRead, output: &mut [Sample]) -> Result<usize> {
output.fill(INVALID_SAMPLE);
Ok(output.len())
}
fn reset(&mut self) {
}
fn bytes_per_sample(&self) -> Option<usize> {
Some(0) }
}