Sound files 1.5. Size

The size of a sound file is equal to the size of the header plus the product of the number of samples, the quantization size, and the number of channels.

For instance, a stereo sound with a duration of 3 seconds, sampled at 44100 Hz, would, when written into a 16-bit NeXT/Sun file, take up a disk space of

28 + 2 * 3.0 * 44100 * 2 = 529228 bytes

whereas the same sound, when averaged to mono, downsampled to 8000 Hz, and written into a μ-law NeXT/Sun file, take up only a disk space of

28 + 1 * 3.0 * 8000 * 1 = 24028 bytes

The first example is typical of CD quality, the second of telephone speech.

Links to this page


© ppgb, January 26, 2000