add new sigc++2 directory
[ardour.git] / libs / libsndfile / src / GSM610 / table.c
1 /*
2  * Copyright 1992 by Jutta Degener and Carsten Bormann, Technische
3  * Universitaet Berlin.  See the accompanying file "COPYRIGHT" for
4  * details.  THERE IS ABSOLUTELY NO WARRANTY FOR THIS SOFTWARE.
5  */
6
7 /*  Most of these tables are inlined at their point of use.
8  */
9
10 /*  4.4 TABLES USED IN THE FIXED POINT IMPLEMENTATION OF THE RPE-LTP
11  *      CODER AND DECODER
12  *
13  *      (Most of them inlined, so watch out.)
14  */
15
16 #define GSM_TABLE_C
17 #include "gsm610_priv.h"
18 #include        "gsm.h"
19
20 /*  Table 4.1  Quantization of the Log.-Area Ratios
21  */
22 /* i                 1      2      3        4      5      6        7       8 */
23 word gsm_A[8]   = {20480, 20480, 20480,  20480,  13964,  15360,   8534,  9036};
24 word gsm_B[8]   = {    0,     0,  2048,  -2560,     94,  -1792,   -341, -1144};
25 word gsm_MIC[8] = { -32,   -32,   -16,    -16,     -8,     -8,     -4,    -4 };
26 word gsm_MAC[8] = {  31,    31,    15,     15,      7,      7,      3,     3 };
27
28
29 /*  Table 4.2  Tabulation  of 1/A[1..8]
30  */
31 word gsm_INVA[8]={ 13107, 13107,  13107, 13107,  19223, 17476,  31454, 29708 };
32
33
34 /*   Table 4.3a  Decision level of the LTP gain quantizer
35  */
36 /*  bc                0         1         2          3                  */
37 word gsm_DLB[4] = {  6554,    16384,    26214,     32767        };
38
39
40 /*   Table 4.3b   Quantization levels of the LTP gain quantizer
41  */
42 /* bc                 0          1        2          3                  */
43 word gsm_QLB[4] = {  3277,    11469,    21299,     32767        };
44
45
46 /*   Table 4.4   Coefficients of the weighting filter
47  */
48 /* i                0      1   2    3   4      5      6     7   8   9    10  */
49 word gsm_H[11] = {-134, -374, 0, 2054, 5741, 8192, 5741, 2054, 0, -374, -134 };
50
51
52 /*   Table 4.5   Normalized inverse mantissa used to compute xM/xmax 
53  */
54 /* i                    0        1    2      3      4      5     6      7   */
55 word gsm_NRFAC[8] = { 29128, 26215, 23832, 21846, 20165, 18725, 17476, 16384 };
56
57
58 /*   Table 4.6   Normalized direct mantissa used to compute xM/xmax
59  */
60 /* i                  0      1       2      3      4      5      6      7   */
61 word gsm_FAC[8] = { 18431, 20479, 22527, 24575, 26623, 28671, 30719, 32767 };
62 /*
63 ** Do not edit or modify anything in this comment block.
64 ** The arch-tag line is a file identity tag for the GNU Arch 
65 ** revision control system.
66 **
67 ** arch-tag: 8957c531-e6b0-4097-9202-da7ca42729ca
68 */
69