Smart Remote 3 nRF52 v1.2
bv32externs.h
1 /*****************************************************************************/
2 /* BroadVoice(R)32 (BV32) Floating-Point ANSI-C Source Code */
3 /* Revision Date: October 5, 2012 */
4 /* Version 1.2 */
5 /*****************************************************************************/
6 
7 /*****************************************************************************/
8 /* Copyright 2000-2012 Broadcom Corporation */
9 /* */
10 /* This software is provided under the GNU Lesser General Public License, */
11 /* version 2.1, as published by the Free Software Foundation ("LGPL"). */
12 /* This program is distributed in the hope that it will be useful, but */
13 /* WITHOUT ANY SUPPORT OR WARRANTY; without even the implied warranty of */
14 /* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the LGPL for */
15 /* more details. A copy of the LGPL is available at */
16 /* http://www.broadcom.com/licenses/LGPLv2.1.php, */
17 /* or by writing to the Free Software Foundation, Inc., */
18 /* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
19 /*****************************************************************************/
20 
21 
22 /*****************************************************************************
23  bv32externs.h : BV32 Floating-Point externs
24 
25  $Log$
26 ******************************************************************************/
27 
28 /* POINTERS */
29 extern Float winl[];
30 extern Float sstwin[];
31 extern int idxord[];
32 extern Float hpfa[];
33 extern Float hpfb[];
34 extern Float adf[];
35 extern Float bdf[];
36 extern Float x[];
37 extern Float x2[];
38 extern Float invk[];
39 extern Float MPTH[];
40 
41 
42 /* LSP Quantization */
43 extern Float lspecb1[LSPECBSZ1*LPCO];
44 extern Float lspecb21[LSPECBSZ21*SVD1];
45 extern Float lspecb22[LSPECBSZ22*SVD2];
46 extern Float lspmean[LPCO];
47 extern Float lspp[LSPPORDER*LPCO];
48 
49 /* Pitch Predictor Codebook */
50 extern Float pp9cb[];
51 
52 /* Log-Gain Quantization */
53 extern Float lgpecb[LGPECBSZ];
54 extern Float lgp[LGPORDER];
55 extern Float lgmean;
56 
57 /* Log-Gain Limitation */
58 extern Float lgclimit[];
59 
60 /* Excitation Codebook */
61 extern Float cccb[CBSZ*VDIM];
62 
63 extern Float lgpecb_nh[];
64 extern Float a_pre[];
65 extern Float b_pre[];
66 
67 /* Function Prototypes */
68 
69 extern Float estlevel(
70 Float lg,
71 Float *level,
72 Float *lmax,
73 Float *lmin,
74 Float *lmean,
75 Float *x1);
76 
77 extern void excdec_w_LT_synth(
78  Float *ltsymd, /* long-term synthesis filter memory at decoder*/
79  short *idx, /* excitation codebook index array for current subframe */
80  Float *gainq, /* quantized linear gains for sub-subframes */
81  Float *b, /* coefficient of 3-tap pitch predictor */
82  short pp, /* pitch period (# of 8 kHz samples) */
83  Float *EE);
84 
85 extern Float gaindec(
86  Float *lgq,
87  short gidx,
88  Float *lgpm,
89  Float *prevlg,
90  Float level,
91  short *nclglim,
92  short lctimer);
93 
94 void gainplc(Float E,
95  Float *lgeqm,
96  Float *lgqm);
97 
98 extern void lspdec(
99  Float *lspq,
100  short *lspidx,
101  Float *lsppm,
102  Float *lspq_last);
103 
104 extern void lspplc(
105  Float *lspq,
106  Float *lsppm);
107 
108 extern int coarsepitch(
109 Float *xw,
110 Float *xwd,
111 Float *dfm,
112 int cpplast);
113 
114 
115 extern int refinepitch(
116 Float *x,
117 int cpp,
118 Float *ppt);
119 
120 extern int pitchtapquan(
121 Float *x,
122 int pp,
123 Float *b);
124 
125 extern void excquan(
126  Float *qv, /* output quantized excitation signal vector */
127  short *idx, /* quantizer codebook index for uq[] vector */
128  Float *d, /* input prediction residual signal vector */
129  Float *h, /* noise feedback filter coefficient array */
130  Float *b, /* coefficient of 3-tap pitch predictor */
131  Float beta, /* coefficient of weighted 3-tap pitch predictor */
132  Float *ltsym, /* long-term synthesis filter memory */
133  Float *ltnfm, /* long-term noise feedback filter memory */
134  Float *stnfm, /* short-term noise feedback filter memory */
135  Float *cb, /* scalar quantizer codebook */
136  int pp); /* pitch period (# of 8 kHz samples) */
137 
138 extern int gainquan(
139  Float *gainq,
140  Float lg,
141  Float *lgpm,
142  Float *prevlg,
143  Float level);
144 
145 extern void lspquan(
146  Float *lspq,
147  short *lspidx,
148  Float *lsp,
149  Float *lsppm);

Documentation feedback | Developer Zone | Subscribe | Updated