Mercurial > libavcodec.hg
comparison ac3dec.c @ 7472:83c16f531a90 libavcodec
Hardcode the table for ungrouping 3 values in 5 bits. It will be reused by
the E-AC-3 decoder.
author | jbr |
---|---|
date | Sun, 03 Aug 2008 21:42:43 +0000 |
parents | 1788013cf23b |
children | e2f3016867a0 |
comparison
equal
deleted
inserted
replaced
7471:1788013cf23b | 7472:83c16f531a90 |
---|---|
148 | 148 |
149 /* generate grouped mantissa tables | 149 /* generate grouped mantissa tables |
150 reference: Section 7.3.5 Ungrouping of Mantissas */ | 150 reference: Section 7.3.5 Ungrouping of Mantissas */ |
151 for(i=0; i<32; i++) { | 151 for(i=0; i<32; i++) { |
152 /* bap=1 mantissas */ | 152 /* bap=1 mantissas */ |
153 b1_mantissas[i][0] = symmetric_dequant( i / 9 , 3); | 153 b1_mantissas[i][0] = symmetric_dequant(ff_ac3_ungroup_3_in_5_bits_tab[i][0], 3); |
154 b1_mantissas[i][1] = symmetric_dequant((i % 9) / 3, 3); | 154 b1_mantissas[i][1] = symmetric_dequant(ff_ac3_ungroup_3_in_5_bits_tab[i][1], 3); |
155 b1_mantissas[i][2] = symmetric_dequant((i % 9) % 3, 3); | 155 b1_mantissas[i][2] = symmetric_dequant(ff_ac3_ungroup_3_in_5_bits_tab[i][2], 3); |
156 } | 156 } |
157 for(i=0; i<128; i++) { | 157 for(i=0; i<128; i++) { |
158 /* bap=2 mantissas */ | 158 /* bap=2 mantissas */ |
159 b2_mantissas[i][0] = symmetric_dequant(ungroup_3_in_7_bits_tab[i][0], 5); | 159 b2_mantissas[i][0] = symmetric_dequant(ungroup_3_in_7_bits_tab[i][0], 5); |
160 b2_mantissas[i][1] = symmetric_dequant(ungroup_3_in_7_bits_tab[i][1], 5); | 160 b2_mantissas[i][1] = symmetric_dequant(ungroup_3_in_7_bits_tab[i][1], 5); |