DirectSound - Features

Features

DirectSound is a user mode API that provides an interface between applications and the sound card driver, enabling applications to produce sounds and play back music.

DirectSound was considered revolutionary when it was introduced in 1995, as it featured multiple simultaneous audio streams and allowed several applications to access the sound card simultaneously. Before that, the game developers were required to implement their own audio rendering engine in software.

DirectSound provides sample rate conversion and sound mixing (volume and pan) for an unlimited number of audio sources, however the practical limits are the number of hardware audio sources and the performance of software mixers.

The DirectSound architecture features a concept of the "ring buffer" which would be continuously played in a cycle. The application programmer creates the sound buffer then continuously queries its state through the "read cursor" and updates it with the "write cursor". There are two types of buffers - a "streaming" buffer, which holds continuous sounds such as background music, and a "static" buffer which holds short sounds.

On supported sound cards, DirectSound would try to use "hardware accelerated" buffers, i.e. the ones which either can be placed in local sound card memory, or can be accessed by the sound card from the system memory. If hardware acceleration is not available, DirectSound would create audio buffers in the system memory and use purely software mixing.

Some late DOS-era "wavetable" sound cards such as Sound Blaster AWE32 and Gravis Ultrasound featured dedicated DSPs, which were borrowed from the digital musics instruments. These cards featured local memory which could be used for buffering multiple audio streams and mixing them on board, thus offloading the CPU and greatly improving the sound quality. However this was only possible in DOS by directly programming the hardware, and full-featured "hardware acceleration" from the local memory was never implemented on these cards, due to complexities of double buffering. Later cards such as Sound Blaster Live!, Audigy and X-Fi are capable of accessing the system memory buffers directly.

Read more about this topic:  DirectSound

Famous quotes containing the word features:

    All visible objects, man, are but as pasteboard masks. But in each event—in the living act, the undoubted deed—there, some unknown but still reasoning thing puts forth the mouldings of its features from behind the unreasoning mask. If man will strike, strike through the mask!
    Herman Melville (1819–1891)

    It is a tribute to the peculiar horror of contemporary life that it makes the worst features of earlier times—the stupefaction of the masses, the obsessed and driven lives of the bourgeoisie—seem attractive by comparison.
    Christopher Lasch (b. 1932)

    “It looks as if
    Some pallid thing had squashed its features flat
    And its eyes shut with overeagerness
    To see what people found so interesting
    In one another, and had gone to sleep
    Of its own stupid lack of understanding,
    Or broken its white neck of mushroom stuff
    Short off, and died against the windowpane.”
    Robert Frost (1874–1963)