code_decode.h
来自「源程序中包含PCMu率与PCM线形之间的编解码」· C头文件 代码 · 共 31 行
H
31 行
#ifndef _CODE_DECODE_H
#define _CODE_DECODE_H
#define ZEROTRAP /* turn on the trap as per the MIL-STD */
#define BIAS 0x84 /* define the add-in bias for 16 bit samples */
#define CLIP 32635 //十六进制为 7F7B
#define QUANT_MASK (0xf) /* Quantization field mask. */
#define SEG_MASK (0x70) /* Segment field mask. */
#define SEG_SHIFT (4) /* Left shift for segment number. */
#define SIGN_BIT (0x80) /* Sign bit for a A-law byte. */
#define ERR_PARAM -1
#define OK 0
extern unsigned char g_uc_ms_lin2ulaw[16384];
extern short int g_s_ms_ulaw2linear[256];
// for code_linear2u.c only
unsigned char linear2ulaw(short int sample);
short int ulaw2linear(unsigned char u_val);
// for extern call
void ulawCreat();
inline int code_linear2ulaw(short int * SrcAddr,unsigned char * DstAddr,short int sample_NUM);
void linearCreat();
inline int code_ulaw2linear(unsigned char * pSrcData,short int * pDstData,short int sample_NUM);
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?