The low level drivers abstract the hardware specific features from the rest of the multimedia code. Those are implemented on top of mmdevapi, as new versions of windows do.
Please note that native low level drivers are not currently supported in Wine, because they either access hardware components or require VxDs to be loaded; Wine does not correctly supports those two so far.
There are two specific low level drivers (msacm.drv for wave input/output, midimap.drv for MIDI output only). These drivers (also present in Windows) allow:
choosing one low level driver between many (we'll discuss how the choice is made later on)
add the possibility to convert stream's format (ie ADPCM => PCM) (this is useful if the format required by the application for playback isn't supported by the soundcard).
add the possibility to filter a stream (adding echo, equalizer... to a wave stream, or modify the instruments that have to be played for a MIDI stream).
Wine currently supports the following (kernel) multimedia interfaces.
Open Sound System (OSS) as supplied in the Linux and FreeBSD kernels by 4Front Technologies. The presence of this driver is checked by configure (depends on the <sys/soundcard.h> file). Source code resides in dlls/wineoss.drv.
Advanced Linux Sound Architecture (ALSA) as supplied in the Linux kernel. Source code resides in dlls/winealsa.drv.
Core Audio as introduced in Mac OS X 10.3. Source code resides in dlls/winecoreaudio.drv.
The Wave mapper device allows to load on-demand audio codecs in order to perform software conversion for the types the actual low level driver (hardware). Those codecs are provided through the standard ACM drivers in MSACM32.DLL.
Wave mapper driver implementation can be found in dlls/winmm/wavemap/ directory. This driver heavily relies on MSACM and MSACM32 DLLs which can be found in dlls/msacm and dlls/msacm32. Those DLLs load ACM drivers which provide the conversion to PCM format (which is normally supported by low level drivers). A Law, uLaw, ADPCM, MP3... fit into the category of non PCM formats.
Midi mapper allows to map each one of 16 MIDI channels to a specific instrument on an installed sound card. This allows for example to support different MIDI instrument definitions (XM, GM...). It also permits to output on a per channel basis to different MIDI renderers.
A built-in MIDI mapper can be found in dlls/winmm/midimap/. It partly provides the same functionality as the Windows' one. It allows to pick up destination channels: you can map a given channel to a specific playback device channel (see the configuration bits for more details).