G711 APIs

[English]

重要

The G711 API v1.0 is the lastest stable G711 APIs. All new applications should use G711 API v1.0.

G711 API Categories

G711 APIs:

API Reference

Header File

Functions

unsigned char linear2alaw(int pcm_val)

G711A encodec pcm data to a-law data.

参数

pcm_val – 16 bit pcm data

返回

  • unsigned char: a-law data after pcm data has been encoded by G711A

int alaw2linear(unsigned char a_val)

G711A decodec a-law data to pcm data.

参数

a_val – 8 bit a-law data

返回

  • int: pcm data after a-law data has been decoded by G711A

unsigned char linear2ulaw(int pcm_val)

G711U encodec pcm data to u-law data.

参数

pcm_val – 16 bit pcm data

返回

  • unsigned char: u-law data after pcm data has been encoded by G711U

int ulaw2linear(unsigned char u_val)

G711U decodec u-law data to pcm data.

参数

u_val – 8 bit u-law data

返回

  • int: pcm data after u-law data has been decoded by G711U