Expand description
Reading and writing RIFF/WAVE audio files.
See the book entry Audio files.
Structs§
- WavAudio
- Decoded audio: interleaved samples normalised to
[-1, 1)(integer formats) or as stored (float).
Enums§
- WavSample
Format - Sample encodings that can be written (and are understood when reading).
Functions§
- encode_
wav - Serialises audio as a canonical WAV file in the requested sample format. Samples outside
[-1, 1)are clipped for the integer formats (scale is 2^(bits-1)). - parse_
wav - Parses a WAV byte stream (PCM 8/16/24/32-bit, IEEE float 32/64-bit, plain or extensible headers).
- read_
wav_ file - Reads a WAV file from disk.
- write_
wav_ file - Writes a WAV file to disk.