SoundSetLineNotify

VOID
SoundSetLineNotify(
PLOCAL_DEVICE_INFO
pLDI,
PSOUND_LINE_NOTIFY
LineNotify
);

The SoundSetLineNotify function specifies a function to be called when the status of the specified device changes.

Parameters

pLDI

Pointer to the LOCAL_DEVICE_INFO structure of the device with which the notification function is to be associated.

LineNotify

Pointer to a notification function. Type is PSOUND_LINE_NOTIFY.

Return Value

None.

Comments

The SoundSetLineNotify function is called by mixer drivers, so they can receive notification of changes to devices associated with mixer lines.

A separate notification function can be registered for each device created with SoundCreateDevice, but code in soundlib.lib calls notification functions only for waveform devices and MIDI synthesizers.

If a driver has registered a notification function by calling SoundSetLineNotify, then soundlib.lib calls the function whenever the status of the device changes (that is, the device starts or stops).

Typically, the driver uses the notification function to send commands to mixer hardware, if necessary, and to call SoundMixerChangedItem, which queues the change and notifies clients.

Drivers calling SoundSetLineNotify must include mixer.h.