mxdMessage

DWORD APIENTRY
mxdMessage (
UINT uDeviceId,
UINT uMsg,
DWORD dwUser,
DWORD dwParam1,
DWORD dwParam2
);

The mxdMessage function is one of the user-mode audio driver entry points. It is the entry point for user-mode mixer drivers.

Parameters

uDeviceId

Device identifier (0, 1, 2, etc.) for the target device.

uMsg

Specifies one of the user-mode audio driver messages.

dwUser

Specifies a device instance identifier. For the MXDM_OPEN message, this is an output parameter. The driver creates the instance identifier and returns it in the address specified as the argument. For all other messages, this is an input parameter. The argument is the instance identifier.

dwParam1

Specifies the first message parameter. Dependent on message type.

dwParam2

Specifies the second message parameter. Dependent on message type.

Return Value

The mxdMessage function returns a value that is dependent upon the message. If the received message is not recognized, the function returns MMSYSERR_NOTSUPPORTED.

Comments

You can use dwUser in any manner you wish. Drivers that can support multiple clients return a different value for each MXDM_OPEN message, in order to keep track of which subsequent messages are being sent by which client.