// hdaudio.h
typedef struct _HDAUDIO_CONVERTER_FORMAT {
union {
struct {
USHORT NumberOfChannels : 4;
USHORT BitsPerSample : 3;
USHORT SampleRate : 7;
USHORT StreamType : 1;
};
USHORT ConverterFormat;
};
} HDAUDIO_CONVERTER_FORMAT, *PHDAUDIO_CONVERTER_FORMAT;
View the official Windows Driver Kit DDI referenceNo description available.
The HDAUDIO_CONVERTER_FORMAT structure specifies the 16-bit encoded stream format for an input or output converter, as defined in the Intel High Definition Audio Specification (see the Intel HD Audio website).
Specifies the number of channels in the stream's data format. For more information, see the Remarks section.
NumberOfChannelsSpecifies the number of channels in the stream's data format. For more information, see the following Remarks section.
BitsPerSampleSpecifies the number of bits per sample. For more information, see the following Remarks section.
SampleRateSpecifies the stream's sample rate. For more information, see the following Remarks section.
StreamTypeSpecifies the stream type. If StreamType=0, the stream contains PCM data. If StreamType=1, the stream contains non-PCM data.
ConverterFormatSpecifies the stream's data format as an encoded 16-bit value. For more information, see the following Remarks section.
For information about the encoding of the individual bitfields in the structure definition, see the discussion of the stream descriptor in the Intel High Definition Audio Specification at the Intel HD Audio website.
The HD Audio bus driver sets the unnamed bitfield in the structure definition to zero.
The AllocateCaptureDmaEngine, AllocateRenderDmaEngine, and ChangeBandwidthAllocation routines take as an input parameter an HDAUDIO_STREAM_FORMAT structure and output the corresponding HDAUDIO_CONVERTER_FORMAT structure. The caller can use the output value to program the input or output converters.
Each valid HDAUDIO_CONVERTER_FORMAT encoding has a one-to-one correspondence to an HDAUDIO_STREAM_FORMAT structure that contains a valid set of parameters.