SimpleAudioSample from WDK audio examples modifications

Hi there!

I'm really stucking on trying to modify the SimpleAudioSample from the WDK audio examples to enable more than 2 channels + modify resolution (up to 32 bit) + modify sample rate ( up to 384khz. I'm newbie on virtual audio driver development, I have tried to read the WDK documents + examples, and also tried to find something already written in this forum, but nothing. So I ask directly on a topic in hope that somebodies enlighten me.

In advance thank you,

1 Like

It is complicated, no argument. Partly because this same mechanism is used for all streaming drivers (video, audio, midi).

You need to set the pin descriptions in speakerwavtable.h to declare the range of formats you might be able to accept. If there are multiple data formats (for example, int16 and float32), then you need several KSDATAFORMAT_WAVEFORMATEXTENSIBLE structures. Then, you change CMiniportWaveRT::DataRangeIntersection to filter out the exact formats you're willing to accept right now. Add some liberal debug prints and the process becomes somewhat more clear.

Thank you Tim for your kind reply! I will test that on Monday