summaryrefslogtreecommitdiffstats
path: root/baseline/source/gsm_enc/private.h
diff options
context:
space:
mode:
Diffstat (limited to 'baseline/source/gsm_enc/private.h')
-rw-r--r--baseline/source/gsm_enc/private.h56
1 files changed, 56 insertions, 0 deletions
diff --git a/baseline/source/gsm_enc/private.h b/baseline/source/gsm_enc/private.h
new file mode 100644
index 0000000..48786b3
--- /dev/null
+++ b/baseline/source/gsm_enc/private.h
@@ -0,0 +1,56 @@
1#ifndef PRIVATE_H
2#define PRIVATE_H
3
4typedef short word; /* 16 bit signed int */
5typedef long longword; /* 32 bit signed int */
6
7typedef unsigned short uword; /* unsigned word */
8typedef unsigned long ulongword; /* unsigned longword */
9
10struct gsm_state {
11
12 word dp0[ 280 ];
13
14 word z1; /* preprocessing.c, Offset_com. */
15 longword L_z2; /* Offset_com. */
16 int mp; /* Preemphasis */
17
18 word u[8]; /* short_term_aly_filter.c */
19 word LARpp[2][8]; /* */
20 word j; /* */
21
22 word nrp; /* 40 */ /* long_term.c, synthesis */
23 word v[9]; /* short_term.c, synthesis */
24 word msr; /* decoder.c, Postprocessing */
25
26 char verbose; /* only used if !NDEBUG */
27 char fast; /* only used if FAST */
28
29};
30
31
32#define MIN_WORD ((-32767)-1)
33#define MAX_WORD ( 32767)
34
35#define MIN_LONGWORD ((-2147483647)-1)
36#define MAX_LONGWORD ( 2147483647)
37
38#define SASR(x, by) ((x) >> (by))
39
40/* Table 4.3a Decision level of the LTP gain quantizer
41 */
42/* bc 0 1 2 3 */
43word gsm_enc_DLB[4] = { 6554, 16384, 26214, 32767 };
44
45
46/* Table 4.5 Normalized inverse mantissa used to compute xM/xmax
47 */
48/* i 0 1 2 3 4 5 6 7 */
49word gsm_enc_NRFAC[8] = { 29128, 26215, 23832, 21846, 20165, 18725, 17476, 16384 };
50
51
52/* Table 4.6 Normalized direct mantissa used to compute xM/xmax
53 */
54/* i 0 1 2 3 4 5 6 7 */
55word gsm_enc_FAC[8] = { 18431, 20479, 22527, 24575, 26623, 28671, 30719, 32767 };
56#endif /* PRIVATE_H */