This project has moved. For the latest updates, please go here.

Convert WMA to WAV ?

Feb 22 at 6:59 PM
Hello, I am trying desperately to convert a WMA byte stream to a WAV, first I've tried this code:
    System.IO.File.WriteAllBytes("wmatemp.wma", data);
    WMAFileReader fileReader = new WMAFileReader("wmatemp.wma");
    WaveStream waveStream = WaveFormatConversionStream.CreatePcmStream(fileReader);
    WAV wav = new WAV(AudioMemStream(waveStream).ToArray());
But everytime I run the program, when it reaches the point where it has to create the fileReader, it crashes, without throwing exception, I found this error in the error log:
"The thread tried to read from or write to a virtual address for which it does not have the appropriate access."
My second attempt was with this code:
MemoryStream wmastream = new MemoryStream(data);
        StreamMediaFoundationReader fileReader = new StreamMediaFoundationReader(wmastream);
        
        WaveStream waveStream = WaveFormatConversionStream.CreatePcmStream(fileReader);
        WAV wav = new WAV(AudioMemStream(waveStream).ToArray());
At this point the program doesn't crash but it still throws an exception, that is
"Requestes feature is not implemented"
I would appreciate any type of help, thank you !