📄 g722main.c
字号:
#include <stdlib.h>
#include "rtdspc.h"
/* Main program for g722 encode and decode demo for 210X0 */
extern int encode(int,int);
extern void decode(int);
extern void reset();
/* outputs of the decode function */
extern int xout1,xout2;
void main()
{
int i,j,t1,t2;
float xf1 = 0.0;
float xf2 = 0.0;
init_evm(); /* INITIALIZE EVALUATION MODULE PARAMETERS */
/* reset, initialize required memory */
reset();
/* note: the g722 standard calls for 16 KHz for voice operation */
while(1) {
t1=getinput();
t2=getinput();
j=encode(t1,t2);
decode(j);
xf1 = (float)xout1;
sendout(xf1);
xf2 = (float)xout2;
sendout(xf2);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -