The OS/2 waveform audio (waveaudio) device allows an application to play or record digital audio using files or application memory buffers. While audio refers to the sound waves (changes in air pressure) that have a perceived effect on the human ear, waveform refers to a digital representation of the original audio sound wave. Using one technique called pulse code modulation (PCM), discrete samples of the sound wave are encoded by an audio adapter at precise intervals. The numerical value of the sample increases when the sound wave's force (loudness) increases. The variation of the sample increases as the frequency of the sound wave increases.
The number of samples per second taken of the original sound wave as well as the precision (or resolution) of the sample dictate the quality of the sound reproduction. Typical sampling rates include 44 kHz, 22 kHz, and 11 kHz, where kHz is an abbreviation for kilohertz or thousands of cycles per second. The sampling precision is usually measured in bits where 8 or 16 bits per sample are representative of most audio adapters. Mono or stereo refers to the number of channels transferring digital audio. Mono represents one channel and stereo represents two channels.
Generally, the higher the sampling rate and resolution, the higher the perceived quality; however this comes at the expense of potentially enormous data rates and file sizes. For example, audio quality equivalent to that produced by a CD audio device requires a sampling rate of 44.1 kHz, and 16-bit resolution for each of the channels in a stereo recording. This information alone results in a data rate of 176 kilobytes per second! Luckily, many applications of digital audio are adequately supported with sampling rates and resolutions as low as 22 kHz and 8 bits respectively. The exact choice of parameters will vary, depending on the requirements of the application.