remove additional C++ comments
[platform/upstream/libvorbis.git] / lib / modes / mode_44_X.h
1 /********************************************************************
2  *                                                                  *
3  * THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE.   *
4  * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS     *
5  * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
6  * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING.       *
7  *                                                                  *
8  * THE OggVorbis SOURCE CODE IS (C) COPYRIGHT 1994-2001             *
9  * by the XIPHOPHORUS Company http://www.xiph.org/                  *
10  *                                                                  *
11  ********************************************************************
12
13  function: predefined encoding modes; 44kHz stereo ~64kbps true VBR
14  last mod: $Id: mode_44_X.h,v 1.1 2001/08/13 11:30:59 xiphmont Exp $
15
16  ********************************************************************/
17
18 #ifndef _V_MODES_44_X_H_
19 #define _V_MODES_44_X_H_
20
21 #include <stdio.h>
22 #include "vorbis/codec.h"
23 #include "backends.h"
24
25 #include "books/line_128x7_class1.vqh"
26 #include "books/line_128x7_class2.vqh"
27
28 #include "books/line_128x7_0sub0.vqh"
29 #include "books/line_128x7_1sub1.vqh"
30 #include "books/line_128x7_1sub2.vqh"
31 #include "books/line_128x7_1sub3.vqh"
32 #include "books/line_128x7_2sub1.vqh"
33 #include "books/line_128x7_2sub2.vqh"
34 #include "books/line_128x7_2sub3.vqh"
35
36 #include "books/line_1024x31_class0.vqh"
37 #include "books/line_1024x31_class1.vqh"
38 #include "books/line_1024x31_class2.vqh"
39 #include "books/line_1024x31_class3.vqh"
40
41 #include "books/line_1024x31_0sub0.vqh"
42 #include "books/line_1024x31_0sub1.vqh"
43 #include "books/line_1024x31_1sub0.vqh"
44 #include "books/line_1024x31_1sub1.vqh"
45 #include "books/line_1024x31_2sub1.vqh"
46 #include "books/line_1024x31_2sub2.vqh"
47 #include "books/line_1024x31_2sub3.vqh"
48 #include "books/line_1024x31_3sub1.vqh"
49 #include "books/line_1024x31_3sub2.vqh"
50 #include "books/line_1024x31_3sub3.vqh"
51
52 #include "books/res_44_Y_128aux.vqh"
53 #include "books/res_44_Y_1024aux.vqh"
54
55 #include "books/res_Z_1.vqh"
56 #include "books/res_Z_2.vqh"
57 #include "books/res_Z_3.vqh"
58 #include "books/res_Z_4.vqh"
59 #include "books/res_Z_5.vqh"
60 #include "books/res_Z_6.vqh"
61 #include "books/res_Z_6a.vqh"
62 #include "books/res_Z_6b.vqh"
63
64 #include "maskadj_Z.h"
65
66 static vorbis_info_psy_global _psy_set_44_XG={
67   0, /* decaydBpms */
68   8,   /* lines per eighth octave */
69   
70   /* thresh sample period, preecho clamp trigger threshhold, range, minenergy */
71   256, {26.f,26.f,26.f,30.f}, {-90.f,-90.f,-90.f,-90.f}, -90.f,
72   -6.f, 
73   
74   0,
75 };
76
77 static struct vp_couple_pass _psy_pass_44_X[]={
78   {1.f,1.f, {0}}
79 };
80
81 static vorbis_info_psy _psy_set_44_X0={
82   ATH_Bark_dB_lineaggressive,
83   -100.,-120.,
84
85   /* tonemaskp */
86   0.f, -24.f,&_vp_tonemask_consbass_Z,
87   /* peakattp, curvelimitp */
88   1, 0, &_vp_peakatt_X,
89
90   /*noisemaskp */
91   1,-24.f,     /* suppress any noise curve over maxspec+n */
92   1.f, 1.f,   /* low/high window */
93   2, 2, -1,
94
95  /*63     125     250     500      1k      2k      4k       8k     16k*/
96   {-30,-30,-30,-30,-30,-30,-15, -15,  0, 0, 0, 0,  0,  0,  1,  2,  3},
97   {1.f,1.f,1.f,1.f,1.f,1.f,.8f,.7f,.7f,.7f,.7f,.7f,.75f,.8f,.8f,.85f,.9f},
98
99   95.f,  /* even decade + 5 is important; saves an rint() later in a
100             tight loop) */
101   1,
102   _psy_pass_44_X
103 };
104
105 static vorbis_info_psy _psy_set_44_XT={
106   ATH_Bark_dB_lineaggressive,
107   -100.f,-120.f,
108
109   /* tonemask */
110   0.f,-20.f,&_vp_tonemask_consbass_Z,
111   /* peakattp,curvelimitp */
112   1, 0,  &_vp_peakatt_X,
113
114   /*noisemaskp */
115   1,  -24.f,     /* suppress any noise curve over maxspec+n */
116       .5f,.5f,   /* low/high window */
117       10,10,100,
118
119   /*63     125     250     500      1k      2k      4k       8k     16k*/
120   {-20,-20,-20,-20,-20,-20,-20, -6,  -3,  0,  0,  0,  0,   0,  0,  0, 0},
121   {1.f,1.f,1.f,1.f,1.f,1.f,.8f,.7f,.7f,.7f,.7f,.7f,.75f,.8f,.8f,.85f,.9f},
122
123   95.f,  /* even decade + 5 is important; saves an rint() later in a
124             tight loop) */
125   1,_psy_pass_44_X
126 };
127
128 static vorbis_info_psy _psy_set_44_X={
129   ATH_Bark_dB_lineaggressive,
130   -100.f,  -120.f,
131
132   /* tonemask */
133   0.f,-20.f,&_vp_tonemask_Z,
134   /* peakattp, curvelimitp */
135   1, 0, &_vp_peakatt_X,
136
137   /*noisemaskp */
138   1,  -24.f,     /* suppress any noise curve over maxspec+n */
139       .5f,.5f,   /* low/high window */
140       10,10,100,
141
142   /*63     125     250     500      1k      2k      4k       8k     16k*/
143   {-20,-20,-20,-20,-20,-20,-10,-6,  -3,  0,  0,  0,  0,   0,  0,  0, 0},
144   {1.f,1.f,1.f,1.f,1.f,1.f,.8f,.7f,.7f,.7f,.7f,.7f,.75f,.8f,.8f,.85f,.9f},
145
146   95.f,  /* even decade + 5 is important; saves an rint() later in a
147             tight loop) */
148   1,_psy_pass_44_X
149 };
150
151 static vorbis_info_time0 _time_set_44_X={0};
152
153 static vorbis_info_floor1 _floor_set_44_X0={
154   3,
155   {0,1,2},
156   
157   {1,3,3},
158   {0,2,2},
159   {-1,0,1},
160   {{2},{-1,3,4,5},{-1,6,7,8}},
161   
162   4,
163   
164   {0,128,  
165    
166    7,
167    
168    2,1,4,
169    23,13,45},
170   
171   60,30,500,
172   999,999,0,18.,
173   8,70,
174   96};
175
176 static vorbis_info_floor1 _floor_set_44_X={
177   10,
178   {0,1,2,2,2,2,2, 3,3,3},
179   
180   {3,4,3,3},
181   {1,1,2,2},
182   {9,10,11,12},
183   {{13,14},
184    {15,16},
185    {-1,17,18,19},
186    {-1,20,21,22},
187   },
188   
189   4,
190   {0,1024,
191    
192    88,31,243,
193    
194    14,54,143,460,
195    
196    6,3,10, 22,18,26, 41,36,47, 
197    69,61,78, 112,99,126, 185,162,211,  
198    329,282,387, 672,553,825
199   },
200   
201   60,30,400,
202   20,8,1,18.,
203   20,600,
204   768};
205
206 static vorbis_info_residue0 _residue_set_44_X0={
207   0,96, 12, 7,23,
208   {0,1,1,1,1,1,7},
209   {25, 26, 27, 28, 29, 30, 31, 32},
210   {9999, 3,9999, 9999, 9999, 9999, 9999},
211   {.5, 1.5f,1.5, 2.5, 7.5, 22.5f},
212   {0},
213   {99, 99,99, 99, 99, 99},
214   {3}};
215
216 static vorbis_info_residue0 _residue_set_44_X={
217   0,768, 32, 7,24,
218   {0,1,1,1,1,1,7},
219   {25, 26, 27, 28, 29, 30, 31, 32},
220   {9999, 4,9999, 9999, 9999, 9999, 9999},
221   {.5, 1.5f,1.5, 2.5, 7.5, 22.5f},
222   {0},
223   {99, 99,99, 99, 99, 99},
224   {3}};
225
226 static vorbis_info_mapping0 _mapping_set_44_X0={
227   1, {0,0}, {0}, {0}, {0}, {0,0}, 0,{0},{0}};
228 static vorbis_info_mapping0 _mapping_set_44_X={
229   1, {0,0}, {0}, {1}, {1}, {1,2}, 0,{0},{0}};
230
231 static vorbis_info_mode _mode_set_44_X0={0,0,0,0};
232 static vorbis_info_mode _mode_set_44_X={1,0,0,1};
233
234 codec_setup_info info_44_X={
235
236   /* smallblock, largeblock */
237   {256, 2048}, 
238   /* modes,maps,times,floors,residues,books,psys */
239   2,          2,    1,     2,       2,   33,   3,
240   /* modes */
241   {&_mode_set_44_X0,&_mode_set_44_X},
242   /* maps */
243   {0,0},{&_mapping_set_44_X0,&_mapping_set_44_X},
244   /* times */
245   {0,0},{&_time_set_44_X},
246   /* floors */
247   {1,1},{&_floor_set_44_X0,&_floor_set_44_X},
248   /* residue */
249   {0,0},{&_residue_set_44_X0,&_residue_set_44_X},
250   /* books */
251     
252   {  
253    &_huff_book_line_128x7_class1,
254    &_huff_book_line_128x7_class2, /* 1 */
255    
256    &_huff_book_line_128x7_0sub0,  /* 2 */
257    &_huff_book_line_128x7_1sub1,  /* 3 */
258    &_huff_book_line_128x7_1sub2,
259    &_huff_book_line_128x7_1sub3,  /* 5 */
260    &_huff_book_line_128x7_2sub1,
261    &_huff_book_line_128x7_2sub2,  /* 7 */
262    &_huff_book_line_128x7_2sub3, 
263
264    &_huff_book_line_1024x31_class0,
265    &_huff_book_line_1024x31_class1, /* 10 */
266    &_huff_book_line_1024x31_class2,
267    &_huff_book_line_1024x31_class3, /* 12 */
268
269    &_huff_book_line_1024x31_0sub0,
270    &_huff_book_line_1024x31_0sub1, /* 14 */
271    &_huff_book_line_1024x31_1sub0, 
272    &_huff_book_line_1024x31_1sub1,
273    &_huff_book_line_1024x31_2sub1,  
274    &_huff_book_line_1024x31_2sub2, /* 18 */
275    &_huff_book_line_1024x31_2sub3, 
276    &_huff_book_line_1024x31_3sub1,
277    &_huff_book_line_1024x31_3sub2,
278    &_huff_book_line_1024x31_3sub3, /* 22 */
279
280    &_huff_book_res_44_Y_128aux, 
281    &_huff_book_res_44_Y_1024aux,
282
283    &_vq_book_res_Z_1,
284    &_vq_book_res_Z_2,
285    &_vq_book_res_Z_3,
286    &_vq_book_res_Z_4,
287    &_vq_book_res_Z_5,
288    &_vq_book_res_Z_6,
289    &_vq_book_res_Z_6a,
290    &_vq_book_res_Z_6b,
291
292   },
293   /* psy */
294   {&_psy_set_44_X0,&_psy_set_44_XT,&_psy_set_44_X},
295   &_psy_set_44_XG
296 };
297
298 #endif