Jump to content


decopression of an avi file into PCM


  • You cannot reply to this topic
No replies to this topic

#1 calltopunit

    New Member

  • Members
  • Pip
  • 1 posts

Posted 23 December 2009 - 08:56 AM

Hello,

I am getting an error in decopression of audio (mp3) content content an avi file into PCM. I am trying to read MP3 content of the file and writing it into the PCM file. The code is as follows.

AVIStreamReadFormat(); //reading the MPEGLAYER3WAVEFORMAT of avi file

acmStreamOpen(&g_mp3stream, NULL, (LPWAVEFORMATEX) (LPMPEGLAYER3WAVEFORMAT) mp3format, waveFormat, NULL, 0, 0, 0);

acmStreamConvert(g_mp3stream,&mp3streamHead, ACM_STREAMCONVERTF_BLOCKALIGN)

I am getting the correct format of LPMPEGLAYER3WAVEFORMAT from AVIStreamReadFormat function and the same I am passing into the acmStreamConvert function.

acmStreamConvert function is returning no error but the cbDstLengthUsed member of the ACMSTREAMHEADER is zero after the call. so the output file content is also zero. I got this code from this forum only (http://www.devmaster...read.php?t=5609), I modified that for avi file but I am getting no output.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users