I am developing a source filter with 1 audio output pin.
This filter is an audio parser that reads audio samples from a file.
The audio is stereo. So I am ending up with 2 buffers of data.
Now how do push them downstream in the FillBuffer method of my source
filter?
Thanx.
> I am developing a source filter with 1 audio output pin.
> This filter is an audio parser that reads audio samples
> from a file. The audio is stereo. So I am ending up with
> 2 buffers of data.
Assuming you have PCM data, if you have 2 buffers, you have
2 mono streams and not 1 stereo stream. To mix the 2 mono
streams into a single stereo stream, simply copy the samples
from the 2 buffers into a third buffer, alternating them:
121212...
--
// Alessandro Angeli
// MVP :: DirectShow / MediaFoundation
// mvpnews at riseoftheants dot com
// http://www.riseoftheants.com/mmx/faq.htm