FreeCalypso > hg > gsm-codec-lib
comparison libtwamr/dec_lag3.h @ 357:fb001496ca8c
libtwamr: integrate dec_lag3.c
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 05 May 2024 22:29:09 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
356:5ccfe176bae1 | 357:fb001496ca8c |
---|---|
1 /* | |
2 ******************************************************************************** | |
3 * | |
4 * GSM AMR-NB speech codec R98 Version 7.6.0 December 12, 2001 | |
5 * R99 Version 3.3.0 | |
6 * REL-4 Version 4.1.0 | |
7 * | |
8 ******************************************************************************** | |
9 * | |
10 * File : dec_lag3.h | |
11 * Purpose : Decoding of fractional pitch lag with 1/3 resolution. | |
12 * Extract the integer and fraction parts of the pitch lag from | |
13 * the received adaptive codebook index. | |
14 * | |
15 ******************************************************************************** | |
16 */ | |
17 #ifndef dec_lag3_h | |
18 #define dec_lag3_h "$Id $" | |
19 | |
20 /* | |
21 ******************************************************************************** | |
22 * INCLUDE FILES | |
23 ******************************************************************************** | |
24 */ | |
25 #include "typedef.h" | |
26 | |
27 /* | |
28 ******************************************************************************** | |
29 * LOCAL VARIABLES AND TABLES | |
30 ******************************************************************************** | |
31 */ | |
32 | |
33 /* | |
34 ******************************************************************************** | |
35 * DEFINITION OF DATA TYPES | |
36 ******************************************************************************** | |
37 */ | |
38 | |
39 /* | |
40 ******************************************************************************** | |
41 * DECLARATION OF PROTOTYPES | |
42 ******************************************************************************** | |
43 */ | |
44 /************************************************************************* | |
45 * FUNCTION: Dec_lag3 | |
46 * | |
47 * PURPOSE: Decoding of fractional pitch lag with 1/3 resolution. | |
48 * Extract the integer and fraction parts of the pitch lag from | |
49 * the received adaptive codebook index. | |
50 * | |
51 * See "Enc_lag3.c" for more details about the encoding procedure. | |
52 * | |
53 * The fractional lag in 1st and 3rd subframes is encoded with 8 bits | |
54 * while that in 2nd and 4th subframes is relatively encoded with 4, 5 | |
55 * and 6 bits depending on the mode. | |
56 * | |
57 *************************************************************************/ | |
58 void Dec_lag3(Word16 index, /* i : received pitch index */ | |
59 Word16 T0_min, /* i : minimum of search range */ | |
60 Word16 T0_max, /* i : maximum of search range */ | |
61 Word16 i_subfr, /* i : subframe flag */ | |
62 Word16 T0_prev, /* i : integer pitch delay of last subframe | |
63 used in 2nd and 4th subframes */ | |
64 Word16 * T0, /* o : integer part of pitch lag */ | |
65 Word16 * T0_frac, /* o : fractional part of pitch lag */ | |
66 Word16 flag4 /* i : flag for encoding with 4 bits */ | |
67 ); | |
68 | |
69 #endif |