next up previous contents index
Next: 5.8.11 ALIEN and NOHEAD File Formats Up: 5.8 Waveform File Formats Previous: 5.8.9 OGI File Format

5.8.10 WAVE File Format

  The WAVE file format is a subset of Microsoft's RIFF specification for the storage of multimedia files. A RIFF file starts out with a file header followed by a sequence of data ``chunks''. A WAVE file is often just a RIFF file with a single ``WAVE'' chunk which consists of two sub-chunks - a ``fmt'' chunk specifying the data format and a ``data'' chunk containing the actual sample data. The WAVE file header contains the following

 
		'RIFF'		- RIFF file identification (4 bytes)

<length> - length field (4 bytes)

'WAVE' - WAVE chunk identification (4 bytes)

'fmt ' - format sub-chunk identification (4 bytes)

flength - length of format sub-chunk (4 byte integer)

format - format specifier (2 byte integer)

chans - number of channels (2 byte integer)

sampsRate - sample rate in Hz (4 byte integer)

bpsec - bytes per second (4 byte integer)

bpsample - bytes per sample (2 byte integer)

bpchan - bits per channel (2 byte integer)

'data' - data sub-chunk identification (4 bytes)

dlength - length of data sub-chunk (4 byte integer)

Note that at present support is only provided for WAVE files containing 16 bit PCM data. The default byte ordering assumed for WAVE data files is VAX (little-endian).


next up previous contents index
Next: 5.8.11 ALIEN and NOHEAD File Formats Up: 5.8 Waveform File Formats Previous: 5.8.9 OGI File Format

ECRL HTK_V2.1: email [email protected]