acmDriverEnum(3mms) — Subroutines
Name
acmDriverEnum --- List the available ACM drivers
Syntax
#include <mme/mme_api.h>
MMRESULT acmDriverEnum(ACMDRIVERENUMCB fnCallback,
DWORD dwInstance,
DWORD fdwEnum)
Arguments
ACMDRIVERENUMCB fnCallback
Specifies the procedure-instance address of the application-defined callback function.
DWORD dwInstance
Specifies a 32-bit application-defined value that is passed to the callback function along with ACM driver information.
DWORD fdwEnum
Specifies the following flag for enumerating ACM drivers:
ACM_DRIVERENUMF_DISABLED
Specifies that disabled ACM drivers should be included in the enumeration. Drivers can be disabled through the Sound Mapper option. If a driver is disabled, the fdwSupport argument to the callback function will have the ACMDRIVERDETAILS_SUPPORTF_DISABLED flag set.
Description
The acmDriverEnum function lists the available Audio Compression Manager (ACM) drivers, continuing until there are no more ACM drivers or the callback function returns FALSE.
Callback
BOOL ACMDRIVERENUMCB acmDriverEnumCallback(HACMDRIVERID hadid,
DWORD dwInstance,
DWORD fdwSupport)
The acmDriverEnumCallback function is a placeholder for an application-defined name, and refers to the callback function used with acmDriverEnum.
The callback function must return TRUE to continue enumeration; to stop enumeration, it must return FALSE.
Callback Arguments
HACMDRIVERID hadid
Specifies an ACM driver identifier.
DWORD dwInstance
Specifies the application-defined value specified in the acmDriverEnum function.
DWORD fdwSupport
Specifies driver-support flags specific to the driver identifier hadid. These flags are identical to the flags specified by the fdwSupport field of the ACMDRIVERDETAILS data structure. This argument can be a combination of the following values:
ACMDRIVERDETAILS_SUPPORTF_CODEC
Specifies that this driver supports conversion between two different format tags. For example, if a driver supports compression from WAVE_FORMAT_PCM to WAVE_FORMAT_ADPCM, then this flag is set.
ACMDRIVERDETAILS_SUPPORTF_CONVERTER
Specifies that this driver supports conversion between two different formats of the same format tag. For example, if a driver supports resampling of WAVE_FORMAT_PCM, then this flag is set.
ACMDRIVERDETAILS_SUPPORTF_FILTER
Specifies that this driver supports a filter (modification of the data without changing any of the format attributes). For example, if a driver supports volume or echo operations on WAVE_FORMAT_PCM, then this flag is set.
ACMDRIVERDETAILS_SUPPORTF_DISABLED
Specifies that this driver has been disabled. An application must specify the ACM_DRIVERENUMF_DISABLED to the acmDriverEnum function to include disabled drivers in the enumeration.
Extensions
None.
Return Values
Return MMSYSERR_NOERROR (zero) if no ACM drivers are installed. Moreover, the callback function will not be called.