Opening and Closing Audio Device Drivers

After getting the capabilities of an audio device, you must open the device
before you can use it. Audio devices aren't guaranteed to be shareable, so a
particular device might not be available when you request it. If this happens, you
should notify the user and allow the user to try to open the device again. When
you open an audio device, be sure to close it as soon as you finish using it.

Use the following functions to open and close different types of audio
devices.