Skip to main content

Module audio

Module audio 

Source
Expand description

Audio source abstraction.

The AudioSource trait is the seam between hardware capture (real cpal callbacks) and the rest of the pipeline. Production code uses CpalAudioSource (step 7); tests drive the same pipeline through FileAudioSource, which replays samples from a fixture WAV.

See ADR-0031 for the rationale behind keeping this seam at the f32-frame level (rather than mocking cpal directly or asserting only at the CLI level).

Structs§

CpalAudioSource
Production AudioSource backed by a cpal input stream.
FileAudioSource
Test AudioSource that replays a fixture WAV in fixed-size chunks.

Traits§

AudioSource
Source of raw interleaved f32 audio samples at a fixed sample rate and channel count.