summaryrefslogtreecommitdiff
path: root/libavcodec/mpegaudiodec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2006-08-24 01:12:26 +0000
committerMichael Niedermayer <michaelni@gmx.at>2006-08-24 01:12:26 +0000
commit3328ec63318141feff512a3da42bc240ce863354 (patch)
tree5d43a0758021e38a47ab1798f6f983020f5327d6 /libavcodec/mpegaudiodec.c
parent3c693e7743dd0e379fea3ab3d3cce8b53c52a1a7 (diff)
faster handling of zero coeffs in the low freq decode
Originally committed as revision 6061 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mpegaudiodec.c')
-rw-r--r--libavcodec/mpegaudiodec.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c
index 0b55ce84af..0c57508ee3 100644
--- a/libavcodec/mpegaudiodec.c
+++ b/libavcodec/mpegaudiodec.c
@@ -1697,6 +1697,14 @@ static int huffman_decode(MPADecodeContext *s, GranuleDef *g,
if (get_bits_count(&s->gb) >= end_pos)
break;
y = get_vlc2(&s->gb, vlc->table, 8, 3);
+
+ if(!y){
+ g->sb_hybrid[s_index ] =
+ g->sb_hybrid[s_index+1] = 0;
+ s_index += 2;
+ continue;
+ }
+
x = y >> 4;
y = y & 0x0f;