Exemple #1
0
        int decode(SFLAudioSample *pcm, unsigned char *data, size_t len)
        {
            for (unsigned char* end = data + len; data < end; ++data, ++pcm)
                *pcm = ALawDecode(*data);

            return len;
        }
Exemple #2
0
DecompressG711ALaw::DecompressG711ALaw(MpAudioAbstract &a)
      : AbstractDecompressor(a)
{
      osPrintf("Decoding: ITU G.711 A-Law\n");
   if (!aLawDecodeTableInitialized) {
      aLawDecodeTableInitialized = true;
      for(int i=0;i<256;i++)
         aLawDecodeTable[i] = ALawDecode(i);
   }
}