cc [ flag... ] file... –lmlib [ library... ] #include <mlib.h> mlib_status mlib_SignalLinear2ADPCM4Bits(mlib_u8 *adpcm, const mlib_s16 *pcm, void *state, mlib_s32 n);
The mlib_SignalLinear2ADPCM4Bits() function performs adaptive differential pulse code modulation (ADPCM) in compliance with the ITU (former CCITT) G.721, G.723, and G.726 specifications. It converts data from 16-bit linear PCM to G.721 or G.726 32kbps 4-bit ADPCM format.
The function takes the following arguments:
ADPCM code array.
Linear PCM sample array.
Internal structure of the codec.
Number of samples in the source array.
The function returns MLIB_SUCCESS if successful. Otherwise it returns MLIB_FAILURE.
See attributes(5) for descriptions of the following attributes:
|
mlib_SignalADPCM2Bits2Linear(3MLIB), mlib_SignalADPCM3Bits2Linear(3MLIB), mlib_SignalADPCM4Bits2Linear(3MLIB), mlib_SignalADPCM5Bits2Linear(3MLIB), mlib_SignalADPCMFree(3MLIB), mlib_SignalADPCMInit(3MLIB), mlib_SignalLinear2ADPCM2Bits(3MLIB), mlib_SignalLinear2ADPCM3Bits(3MLIB), mlib_SignalLinear2ADPCM5Bits(3MLIB), attributes(5)