annotate libgsmhr1/typedefs.h @ 498:65f672c43dc8

libgsmhr1/typedefs.h: import original
author Mychaela Falconia <falcon@freecalypso.org>
date Wed, 19 Jun 2024 00:49:48 +0000
parents
children 446a4a2955ba
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
498
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*******************************************************************
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 *
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 * typedef statements of types used in all half-rate GSM routines
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 *
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 ******************************************************************/
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 #ifndef __TYPEDEFS
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 #define __TYPEDEFS
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 #define DATE "August 8, 1996 "
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 #define VERSION "Version 4.2 "
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 #define LW_SIGN (long)0x80000000 /* sign bit */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 #define LW_MIN (long)0x80000000
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 #define LW_MAX (long)0x7fffffff
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 #define SW_SIGN (short)0x8000 /* sign bit for Shortword type */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 #define SW_MIN (short)0x8000 /* smallest Ram */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 #define SW_MAX (short)0x7fff /* largest Ram */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 /* Definition of Types *
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 ***********************/
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 typedef long int Longword; /* 32 bit "accumulator" (L_*) */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 typedef short int Shortword; /* 16 bit "register" (sw*) */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 typedef short int ShortwordRom; /* 16 bit ROM data (sr*) */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 typedef long int LongwordRom; /* 32 bit ROM data (L_r*) */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 struct NormSw
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 { /* normalized Shortword fractional
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 * number snr.man precedes snr.sh (the
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 * shift count)i */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 Shortword man; /* "mantissa" stored in 16 bit
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 * location */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 Shortword sh; /* the shift count, stored in 16 bit
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 * location */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 };
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 /* Global constants *
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 ********************/
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 #define NP 10 /* order of the lpc filter */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 #define N_SUB 4 /* number of subframes */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 #define F_LEN 160 /* number of samples in a frame */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 #define S_LEN 40 /* number of samples in a subframe */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 #define A_LEN 170 /* LPC analysis length */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 #define OS_FCTR 6 /* maximum LTP lag oversampling
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 * factor */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 #define OVERHANG 8 /* vad parameter */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 #define strStr strStr16
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 /* global variables */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 /********************/
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 extern int giFrmCnt; /* 0,1,2,3,4..... */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 extern int giSfrmCnt; /* 0,1,2,3 */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 extern int giDTXon; /* DTX Mode on/off */
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60
65f672c43dc8 libgsmhr1/typedefs.h: import original
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 #endif