This section gives the required and optional messages for waveform input device drivers. See “Audio Device Driver Reference,” later in this chapter, for detailed information on these messages.
The widMessage entry-point function for waveform input drivers must support the following messages.
Adds a buffer to the input queue.
Closes and deallocates a waveform input device.
Requests the capabilities of a waveform input device.
Requests the number of waveform input devices a driver supports.
Requests the current input recording position.
Opens and allocates a waveform input device.
Stops waveform input and returns all data buffers to the client application.
Begins waveform input.
Ends waveform input.
The widMessage entry-point function for waveform input drivers can optionally support the following messages, depending on whether the driver requires any special preparation to client data buffers.
Requests that the driver prepare a data buffer for input.
Requests that a driver clean up the preparation previously done on a data buffer.
In addition to receiving messages, drivers must notify clients when certain events occur. Waveform input drivers notify clients by sending one of the following messages using the DriverCallback function.
Notifies a client application when a device is closed.
Notifies a client application when the driver is finished with a data buffer and is returning it to the client.
Notifies a client application when a device is opened.