Note: DirectSound is being replaced by XAudio2 and will be removed from the SDK in the near future and so should now be considered deprecated.
The DirectSound API allows you to play back sound effects in your game. Unlike DirectShow you can play multiple sounds at once. You can also:
Note: Microsoft intend to replace DirectSound with another API in the near future. This will be Xbox and PC cross platform.
DirectSound is not as easy to use as some of the other DirectX APIs. For instance you need to load .wav files yourself (there are no handy functions like in Direct3D). I have created a demo application that demonstrates playing multiple sounds using DirectSound and the dsutil files that came with an earlier version of the SDK. You can download the executable here: SoundPlayerDemo.zip. The source code is available here: SoundPlayerSource.zip. Most of the work is done in the CSoundPlayer class. This is briefly described below:
For general DirectX questions and answers please see this page: DirectX.