Asterisk - The Open Source Telephony Project GIT-master-b023714
Loading...
Searching...
No Matches
Data Structures | Macros | Typedefs
iLBC_define.h File Reference
#include <string.h>
Include dependency graph for iLBC_define.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  iLBC_Dec_Inst_t_
 
struct  iLBC_Enc_Inst_t_
 
struct  iLBC_ULP_Inst_t_
 

Macros

#define BLOCKL_20MS   160
 
#define BLOCKL_30MS   240
 
#define BLOCKL_MAX   240
 
#define BYTE_LEN   8
 
#define CB_EXPAND   2
 
#define CB_FILTERLEN   2*4
 
#define CB_HALFFILTERLEN   4
 
#define CB_MAXGAIN   (float)1.3
 
#define CB_MEML   147
 
#define CB_NSTAGES   3
 
#define CB_RESRANGE   34
 
#define DELAY_DS   3
 
#define ENH_ALPHA0   (float)0.05
 
#define ENH_BLOCKL   80 /* block length */
 
#define ENH_BLOCKL_HALF   (ENH_BLOCKL/2)
 
#define ENH_BUFL   (ENH_NBLOCKS_TOT)*ENH_BLOCKL
 
#define ENH_CORRDIM   (2*ENH_SLOP+1)
 
#define ENH_FL0
 
#define ENH_HL
 
#define ENH_NBLOCKS   (BLOCKL_MAX/ENH_BLOCKL)
 
#define ENH_NBLOCKS_EXTRA   5
 
#define ENH_NBLOCKS_TOT
 
#define ENH_OVERHANG   2
 
#define ENH_PLOCSL
 
#define ENH_SLOP
 
#define ENH_UPS0   4 /* upsampling rate */
 
#define ENH_VECTL   (ENH_BLOCKL+2*ENH_FL0)
 
#define EPS   (float)2.220446049250313e-016
 
#define FACTOR_DS   2
 
#define FILTERORDER_DS   7
 
#define FLOAT_MAX   (float)1.0e37
 
#define LPC_ASYMDIFF   20
 
#define LPC_BW   (float)60.0
 
#define LPC_CHIRP_SYNTDENUM   (float)0.9025
 
#define LPC_CHIRP_WEIGHTDENUM   (float)0.4222
 
#define LPC_FILTERORDER   10
 
#define LPC_HALFORDER   (LPC_FILTERORDER/2)
 
#define LPC_LOOKBACK   60
 
#define LPC_N_20MS   1
 
#define LPC_N_30MS   2
 
#define LPC_N_MAX   2
 
#define LPC_WN   (float)1.0001
 
#define LSF_NSPLIT   3
 
#define LSF_NUMBER_OF_STEPS   4
 
#define MAX_SAMPLE   32767
 
#define MIN_SAMPLE   -32768
 
#define NASUB_20MS   2
 
#define NASUB_30MS   4
 
#define NASUB_MAX   4
 
#define NO_OF_BYTES_20MS   38
 
#define NO_OF_BYTES_30MS   50
 
#define NO_OF_WORDS_20MS   19
 
#define NO_OF_WORDS_30MS   25
 
#define NSUB_20MS   4
 
#define NSUB_30MS   6
 
#define NSUB_MAX   6
 
#define PI   (float)3.14159265358979323846
 
#define PI2   (float)0.159154943
 
#define STATE_BITS   3
 
#define STATE_LEN   80
 
#define STATE_SHORT_LEN_20MS   57
 
#define STATE_SHORT_LEN_30MS   58
 
#define SUBL   40
 
#define TWO_PI   (float)6.283185307
 
#define ULP_CLASSES   3
 

Typedefs

typedef struct iLBC_Dec_Inst_t_ iLBC_Dec_Inst_t
 
typedef struct iLBC_Enc_Inst_t_ iLBC_Enc_Inst_t
 
typedef struct iLBC_ULP_Inst_t_ iLBC_ULP_Inst_t
 

Macro Definition Documentation

◆ BLOCKL_20MS

#define BLOCKL_20MS   160

Definition at line 19 of file iLBC_define.h.

◆ BLOCKL_30MS

#define BLOCKL_30MS   240

Definition at line 20 of file iLBC_define.h.

◆ BLOCKL_MAX

#define BLOCKL_MAX   240

Definition at line 21 of file iLBC_define.h.

◆ BYTE_LEN

#define BYTE_LEN   8

Definition at line 100 of file iLBC_define.h.

◆ CB_EXPAND

#define CB_EXPAND   2

Definition at line 57 of file iLBC_define.h.

◆ CB_FILTERLEN

#define CB_FILTERLEN   2*4

Definition at line 59 of file iLBC_define.h.

◆ CB_HALFFILTERLEN

#define CB_HALFFILTERLEN   4

Definition at line 60 of file iLBC_define.h.

◆ CB_MAXGAIN

#define CB_MAXGAIN   (float)1.3

Definition at line 62 of file iLBC_define.h.

◆ CB_MEML

#define CB_MEML   147

Definition at line 58 of file iLBC_define.h.

◆ CB_NSTAGES

#define CB_NSTAGES   3

Definition at line 56 of file iLBC_define.h.

◆ CB_RESRANGE

#define CB_RESRANGE   34

Definition at line 61 of file iLBC_define.h.

◆ DELAY_DS

#define DELAY_DS   3

Definition at line 90 of file iLBC_define.h.

◆ ENH_ALPHA0

#define ENH_ALPHA0   (float)0.05

Definition at line 85 of file iLBC_define.h.

◆ ENH_BLOCKL

#define ENH_BLOCKL   80 /* block length */

Definition at line 66 of file iLBC_define.h.

◆ ENH_BLOCKL_HALF

#define ENH_BLOCKL_HALF   (ENH_BLOCKL/2)

Definition at line 67 of file iLBC_define.h.

◆ ENH_BUFL

#define ENH_BUFL   (ENH_NBLOCKS_TOT)*ENH_BLOCKL

Definition at line 84 of file iLBC_define.h.

◆ ENH_CORRDIM

#define ENH_CORRDIM   (2*ENH_SLOP+1)

Definition at line 80 of file iLBC_define.h.

◆ ENH_FL0

#define ENH_FL0
Value:
3 /* 2*FLO+1 is the length of
each filter */

Definition at line 73 of file iLBC_define.h.

119{
120 int lsf_bits[6][ULP_CLASSES+2];
121 int start_bits[ULP_CLASSES+2];
122 int startfirst_bits[ULP_CLASSES+2];
123 int scale_bits[ULP_CLASSES+2];
124 int state_bits[ULP_CLASSES+2];
125 int extra_cb_index[CB_NSTAGES][ULP_CLASSES+2];
126 int extra_cb_gain[CB_NSTAGES][ULP_CLASSES+2];
127 int cb_index[NSUB_MAX][CB_NSTAGES][ULP_CLASSES+2];
128 int cb_gain[NSUB_MAX][CB_NSTAGES][ULP_CLASSES+2];
130
131 /* type definition encoder instance */
132
133
134
135
136
137 typedef struct iLBC_Enc_Inst_t_ {
138
139 /* flag for frame size mode */
140 int mode;
141
142 /* basic parameters for different frame sizes */
143 int blockl;
144 int nsub;
145 int nasub;
147 int lpc_n;
148 int state_short_len;
150
151 /* analysis filter state */
152 float anaMem[LPC_FILTERORDER];
153
154 /* old lsf parameters for interpolation */
155 float lsfold[LPC_FILTERORDER];
157
158 /* signal buffer for LP analysis */
160
161 /* state of input HP filter */
162 float hpimem[4];
163
165
166 /* type definition decoder instance */
167 typedef struct iLBC_Dec_Inst_t_ {
168
169 /* flag for frame size mode */
170 int mode;
171
172 /* basic parameters for different frame sizes */
173 int blockl;
174 int nsub;
175 int nasub;
177 int lpc_n;
178 int state_short_len;
180
181 /* synthesis filter state */
183
184 /* old LSF for interpolation */
185
186
187
188
189
191
192 /* pitch lag estimated in enhancer and used in PLC */
193 int last_lag;
194
195 /* PLC state information */
197 float prevLpc[LPC_FILTERORDER+1];
199 float per;
200 unsigned long seed;
201
202 /* previous synthesis filter parameters */
204
205 /* state of output HP filter */
206 float hpomem[4];
207
208 /* enhancer state information */
209 int use_enhancer;
210 float enh_buf[ENH_BUFL];
212
214
215 #endif
#define LPC_LOOKBACK
Definition iLBC_define.h:43
struct iLBC_Dec_Inst_t_ iLBC_Dec_Inst_t
#define BLOCKL_MAX
Definition iLBC_define.h:21
#define CB_NSTAGES
Definition iLBC_define.h:56
struct iLBC_ULP_Inst_t_ iLBC_ULP_Inst_t
#define SUBL
Definition iLBC_define.h:33
#define LPC_FILTERORDER
Definition iLBC_define.h:40
#define NSUB_MAX
Definition iLBC_define.h:24
#define ENH_BUFL
Definition iLBC_define.h:84
#define ENH_NBLOCKS_TOT
Definition iLBC_define.h:83
struct iLBC_Enc_Inst_t_ iLBC_Enc_Inst_t
#define ULP_CLASSES
float old_syntdenum[(LPC_FILTERORDER+1) *NSUB_MAX]
const iLBC_ULP_Inst_t * ULP_inst
float syntMem[LPC_FILTERORDER]
float enh_buf[ENH_BUFL]
unsigned long seed
float enh_period[ENH_NBLOCKS_TOT]
float prevResidual[NSUB_MAX *SUBL]
float prevLpc[LPC_FILTERORDER+1]
float lsfdeqold[LPC_FILTERORDER]
const iLBC_ULP_Inst_t * ULP_inst
float lsfold[LPC_FILTERORDER]
float anaMem[LPC_FILTERORDER]
float lpc_buffer[LPC_LOOKBACK+BLOCKL_MAX]
float lsfdeqold[LPC_FILTERORDER]

◆ ENH_HL

#define ENH_HL
Value:
3 /* 2*ENH_HL+1 is number blocks
in said second sequence */

Definition at line 68 of file iLBC_define.h.

◆ ENH_NBLOCKS

#define ENH_NBLOCKS   (BLOCKL_MAX/ENH_BLOCKL)

Definition at line 81 of file iLBC_define.h.

◆ ENH_NBLOCKS_EXTRA

#define ENH_NBLOCKS_EXTRA   5

Definition at line 82 of file iLBC_define.h.

◆ ENH_NBLOCKS_TOT

#define ENH_NBLOCKS_TOT
Value:
8 /* ENH_NBLOCKS +
ENH_NBLOCKS_EXTRA */

Definition at line 83 of file iLBC_define.h.

◆ ENH_OVERHANG

#define ENH_OVERHANG   2

Definition at line 71 of file iLBC_define.h.

◆ ENH_PLOCSL

#define ENH_PLOCSL
Value:
20 /* pitch-estimates and pitch-
locations buffer length */

Definition at line 70 of file iLBC_define.h.

◆ ENH_SLOP

#define ENH_SLOP
Value:
2 /* max difference estimated and
correct pitch period */

Definition at line 69 of file iLBC_define.h.

◆ ENH_UPS0

#define ENH_UPS0   4 /* upsampling rate */

Definition at line 72 of file iLBC_define.h.

◆ ENH_VECTL

#define ENH_VECTL   (ENH_BLOCKL+2*ENH_FL0)

Definition at line 74 of file iLBC_define.h.

◆ EPS

#define EPS   (float)2.220446049250313e-016

Definition at line 106 of file iLBC_define.h.

◆ FACTOR_DS

#define FACTOR_DS   2

Definition at line 91 of file iLBC_define.h.

◆ FILTERORDER_DS

#define FILTERORDER_DS   7

Definition at line 89 of file iLBC_define.h.

◆ FLOAT_MAX

#define FLOAT_MAX   (float)1.0e37

Definition at line 105 of file iLBC_define.h.

◆ LPC_ASYMDIFF

#define LPC_ASYMDIFF   20

Definition at line 47 of file iLBC_define.h.

◆ LPC_BW

#define LPC_BW   (float)60.0

Definition at line 48 of file iLBC_define.h.

◆ LPC_CHIRP_SYNTDENUM

#define LPC_CHIRP_SYNTDENUM   (float)0.9025

Definition at line 41 of file iLBC_define.h.

◆ LPC_CHIRP_WEIGHTDENUM

#define LPC_CHIRP_WEIGHTDENUM   (float)0.4222

Definition at line 42 of file iLBC_define.h.

◆ LPC_FILTERORDER

#define LPC_FILTERORDER   10

Definition at line 40 of file iLBC_define.h.

◆ LPC_HALFORDER

#define LPC_HALFORDER   (LPC_FILTERORDER/2)

Definition at line 52 of file iLBC_define.h.

◆ LPC_LOOKBACK

#define LPC_LOOKBACK   60

Definition at line 43 of file iLBC_define.h.

◆ LPC_N_20MS

#define LPC_N_20MS   1

Definition at line 44 of file iLBC_define.h.

◆ LPC_N_30MS

#define LPC_N_30MS   2

Definition at line 45 of file iLBC_define.h.

◆ LPC_N_MAX

#define LPC_N_MAX   2

Definition at line 46 of file iLBC_define.h.

◆ LPC_WN

#define LPC_WN   (float)1.0001

Definition at line 49 of file iLBC_define.h.

◆ LSF_NSPLIT

#define LSF_NSPLIT   3

Definition at line 50 of file iLBC_define.h.

◆ LSF_NUMBER_OF_STEPS

#define LSF_NUMBER_OF_STEPS   4

Definition at line 51 of file iLBC_define.h.

◆ MAX_SAMPLE

#define MAX_SAMPLE   32767

Definition at line 109 of file iLBC_define.h.

◆ MIN_SAMPLE

#define MIN_SAMPLE   -32768

Definition at line 108 of file iLBC_define.h.

◆ NASUB_20MS

#define NASUB_20MS   2

Definition at line 25 of file iLBC_define.h.

◆ NASUB_30MS

#define NASUB_30MS   4

Definition at line 31 of file iLBC_define.h.

◆ NASUB_MAX

#define NASUB_MAX   4

Definition at line 32 of file iLBC_define.h.

◆ NO_OF_BYTES_20MS

#define NO_OF_BYTES_20MS   38

Definition at line 95 of file iLBC_define.h.

◆ NO_OF_BYTES_30MS

#define NO_OF_BYTES_30MS   50

Definition at line 96 of file iLBC_define.h.

◆ NO_OF_WORDS_20MS

#define NO_OF_WORDS_20MS   19

Definition at line 97 of file iLBC_define.h.

◆ NO_OF_WORDS_30MS

#define NO_OF_WORDS_30MS   25

Definition at line 98 of file iLBC_define.h.

◆ NSUB_20MS

#define NSUB_20MS   4

Definition at line 22 of file iLBC_define.h.

◆ NSUB_30MS

#define NSUB_30MS   6

Definition at line 23 of file iLBC_define.h.

◆ NSUB_MAX

#define NSUB_MAX   6

Definition at line 24 of file iLBC_define.h.

◆ PI

#define PI   (float)3.14159265358979323846

Definition at line 107 of file iLBC_define.h.

◆ PI2

#define PI2   (float)0.159154943

Definition at line 111 of file iLBC_define.h.

◆ STATE_BITS

#define STATE_BITS   3

Definition at line 99 of file iLBC_define.h.

◆ STATE_LEN

#define STATE_LEN   80

Definition at line 34 of file iLBC_define.h.

◆ STATE_SHORT_LEN_20MS

#define STATE_SHORT_LEN_20MS   57

Definition at line 36 of file iLBC_define.h.

◆ STATE_SHORT_LEN_30MS

#define STATE_SHORT_LEN_30MS   58

Definition at line 35 of file iLBC_define.h.

◆ SUBL

#define SUBL   40

Definition at line 33 of file iLBC_define.h.

◆ TWO_PI

#define TWO_PI   (float)6.283185307

Definition at line 110 of file iLBC_define.h.

◆ ULP_CLASSES

#define ULP_CLASSES   3

Definition at line 101 of file iLBC_define.h.

Typedef Documentation

◆ iLBC_Dec_Inst_t

◆ iLBC_Enc_Inst_t

◆ iLBC_ULP_Inst_t