residue_8.h 3.2 KB

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