The mixerGetDevCaps function queries a specified mixer device to determine its capabilities.

MMRESULT mixerGetDevCaps(
  UINT_PTR    uMxId,    
  LPMIXERCAPS pmxcaps,  
  UINT        cbmxcaps  



Identifier or handle of an open mixer device.


Pointer to a MIXERCAPS structure that receives information about the capabilities of the device.


Size, in bytes, of the MIXERCAPS structure.

Return Values

Returns MMSYSERR_NOERROR if successful or an error otherwise. Possible error values include the following.

Value Description
MMSYSERR_BADDEVICEID The specified device identifier is out of range.
MMSYSERR_INVALHANDLE The mixer device handle is invalid.
MMSYSERR_INVALPARAM One or more parameters are invalid.


Use the mixerGetNumDevs function to determine the number of mixer devices present in the system. The device identifier specified by uMxId varies from zero to one less than the number of mixer devices present.

Only the number of bytes (or less) of information specified in cbmxcaps is copied to the location pointed to by pmxcaps. If cbmxcaps is zero, nothing is copied, and the function returns successfully.

This function also accepts a mixer device handle returned by the mixerOpen function as the uMxId parameter. The application should cast the HMIXER handle to a UINT.


  Windows NT/2000/XP: Included in Windows NT 3.1 and later.
  Windows 95/98/Me: Included in Windows 95 and later.
  Header: Declared in Mmsystem.h; include Windows.h.
  Library: Use Winmm.lib.
  Unicode: Implemented as Unicode and ANSI versions on Windows NT/2000/XP.

See Also

Audio Mixers, Audio Mixer Functions, MIXERCAPS, mixerGetNumDevs, mixerOpen