All sample rates/modes with fresh training now in CVS.
[platform/upstream/libvorbis.git] / lib / modes / residue_8.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-2002             *
9  * by the XIPHOPHORUS Company http://www.xiph.org/                  *
10  *                                                                  *
11  ********************************************************************
12
13  function: toplevel residue templates 8/11kHz
14  last mod: $Id: residue_8.h,v 1.2 2002/07/11 06:41:04 xiphmont Exp $
15
16  ********************************************************************/
17
18 #include "vorbis/codec.h"
19 #include "backends.h"
20
21 /***** residue backends *********************************************/
22
23 static static_bookblock _resbook_8s_0={
24   {
25     {0},{0,0,&_8c0_s_p1_0},{0,0,&_8c0_s_p2_0},{0,0,&_8c0_s_p3_0},
26     {0,0,&_8c0_s_p4_0},{0,0,&_8c0_s_p5_0},{0,0,&_8c0_s_p6_0},
27     {&_8c0_s_p7_0,&_8c0_s_p7_1},{&_8c0_s_p8_0,&_8c0_s_p8_1},
28     {&_8c0_s_p9_0,&_8c0_s_p9_1,&_8c0_s_p9_2}
29    }
30 };
31 static static_bookblock _resbook_8s_1={
32   {
33     {0},{0,0,&_8c1_s_p1_0},{0,0,&_8c1_s_p2_0},{0,0,&_8c1_s_p3_0},
34     {0,0,&_8c1_s_p4_0},{0,0,&_8c1_s_p5_0},{0,0,&_8c1_s_p6_0},
35     {&_8c1_s_p7_0,&_8c1_s_p7_1},{&_8c1_s_p8_0,&_8c1_s_p8_1},
36     {&_8c1_s_p9_0,&_8c1_s_p9_1,&_8c1_s_p9_2}
37    }
38 };
39
40 static vorbis_residue_template _res_8s_0[]={
41   {2,0,  &_residue_44_mid,
42    &_huff_book__8c0_s_single,&_huff_book__8c0_s_single,
43    &_resbook_8s_0,&_resbook_8s_0},
44 };
45 static vorbis_residue_template _res_8s_1[]={
46   {2,0,  &_residue_44_mid,
47    &_huff_book__8c1_s_single,&_huff_book__8c1_s_single,
48    &_resbook_8s_1,&_resbook_8s_1},
49 };
50
51 static vorbis_mapping_template _mapres_template_8_stereo[2]={
52   { _map_nominal, _res_8s_0 }, /* 0 */
53   { _map_nominal, _res_8s_1 }, /* 1 */
54 };
55
56 static static_bookblock _resbook_8u_0={
57   {
58     {0},
59     {0,0,&_8u0__p1_0},
60     {0,0,&_8u0__p2_0},
61     {0,0,&_8u0__p3_0},
62     {0,0,&_8u0__p4_0},
63     {0,0,&_8u0__p5_0},
64     {&_8u0__p6_0,&_8u0__p6_1},
65     {&_8u0__p7_0,&_8u0__p7_1,&_8u0__p7_2}
66    }
67 };
68 static static_bookblock _resbook_8u_1={
69   {
70     {0},
71     {0,0,&_8u1__p1_0},
72     {0,0,&_8u1__p2_0},
73     {0,0,&_8u1__p3_0},
74     {0,0,&_8u1__p4_0},
75     {0,0,&_8u1__p5_0},
76     {0,0,&_8u1__p6_0},
77     {&_8u1__p7_0,&_8u1__p7_1},
78     {&_8u1__p8_0,&_8u1__p8_1},
79     {&_8u1__p9_0,&_8u1__p9_1,&_8u1__p9_2}
80    }
81 };
82
83 static vorbis_residue_template _res_8u_0[]={
84   {1,0,  &_residue_44_low_un,
85    &_huff_book__8u0__single,&_huff_book__8u0__single,
86    &_resbook_8u_0,&_resbook_8u_0},
87 };
88 static vorbis_residue_template _res_8u_1[]={
89   {1,0,  &_residue_44_mid_un,
90    &_huff_book__8u1__single,&_huff_book__8u1__single,
91    &_resbook_8u_1,&_resbook_8u_1},
92 };
93
94 static vorbis_mapping_template _mapres_template_8_uncoupled[2]={
95   { _map_nominal_u, _res_8u_0 }, /* 0 */
96   { _map_nominal_u, _res_8u_1 }, /* 1 */
97 };