Using High-Definition Audio (Microsoft Media Foundation)
High-definition audio, in the context of the Windows Media Audio codecs, is any audio type with more than two channels or more than 16 bits per sample. High-definition audio is supported by the Professional and Lossless categories of the Windows Media Audio Encoder.
Uncompressed high-definition audio types are defined using the WAVEFORMATEXTENSIBLE structure. WAVEFORMATEXTENSIBLE is a structured extension of the WAVEFORMATEX structure. When you are using DMOs, the formattype member of the DMO_MEDIA_TYPE structure that describes a high-definition audio type must be set to WMCFORMAT_WaveFormatEx, just as it is for normal audio; there is no special format identifier for WAVEFORMATEXTENSIBLE. If a format uses WAVEFORMATEXTENSIBLE , you must set the cbSize member of the WAVEFORMATEX structure to 22.
When using Media Foundation, you can construct the correct media type from a WAVEFORMATEXTENSIBLE structure by using the function MFInitMediaTypeFromWaveFormatEx.
The multi-channel output types supported by the Windows Media Audio 10 Professional codec do not use WAVEFORMATEXTENSIBLE, but report the correct number of channels and bits per sample in the WAVEFORMATEX structure. As with all audio types describing compressed Windows Media Audio content, there is additional information appended to the WAVEFORMATEX structure that is used by the decoder for decompression.
Decoding High-Definition Audio
To decode high-definition audio, you must set the MFPKEY_WMADEC_HIRESOUTPUT property to VARIANT_TRUE. If this property is not set, the decoder will deliver stereo content with a maximum of 16 bits per sample, regardless of the compressed format.
Note
High-definition audio is supported only for Windows XP, Windows Vista and later. On earlier versions of Windows, Windows Media Audio content encoded with high definition is rendered as two-channel audio with a maximum of 16 bits per sample.
Related topics