[LAU] How to decode raw ADPCM data?

Jesse Chappell jesse at essej.net
Wed Mar 12 09:31:13 EDT 2008


On Wed, Mar 12, 2008 at 5:43 AM, Jozef Henzl <popcorp86 at gmail.com> wrote:
> Hello,
>  Does anyone know which tool or library i can use to decode audio data stored
>  in a ADPCM header-less file? (8kHz, 1 channel, (12,16,25 or 32) bit)
>  I've tried sox and libsamplerate, but both throws an error.

>  and with sndfile:
>  <code snip>
>  sfinfo.format = SF_FORMAT_IMA_ADPCM | SF_FORMAT_RAW;
>  sfinfo.samplerate = 8000;
>  sfinfo.channels = 1;
>  if ((fpr = sf_open ("data.adpcm", SFM_READ, &sfinfo)) == NULL)
>  ...
>  </code snip>
>

Try one of the following sndfile formats with the RAW (from sndfile.h)

   SF_FORMAT_GSM610                = 0x0020,               /* GSM 6.10
encoding. */
   SF_FORMAT_VOX_ADPCM             = 0x0021,               /* OKI /
Dialogix ADPCM */

   SF_FORMAT_G721_32               = 0x0030,               /* 32kbs
G721 ADPCM encoding. */
   SF_FORMAT_G723_24               = 0x0031,               /* 24kbs
G723 ADPCM encoding. */
   SF_FORMAT_G723_40               = 0x0032,               /* 40kbs
G723 ADPCM encoding. */

jlc



More information about the Linux-audio-user mailing list