I'm trying to convert a stereo .wav file to mono using NAudio. One requirement is that I cannot use any native calls, as I need to run this code on Azure. Here's what I came with:
using (var waveFileReader = new WaveFileReader(sourceFileName))
{
var toMono = new StereoToMonoProvider16(waveFileReader);
WaveFileWriter.CreateWaveFile(destFileName, toMono);
}
My code works without errors, but the output is a file that contains pure silence.
Is there any other way to convert a file to mono?