diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2003-10-11 19:40:45 +0000 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2003-10-11 19:40:45 +0000 |
commit | 91381201f0ed87718477e4fdb903c76289faa175 (patch) | |
tree | 3b51da8f37c4eed5ed42e4743a40fc6f538a5998 /libavcodec | |
parent | 6cbff2f44a76b916756b76c9eb478afc927ea240 (diff) | |
download | ffmpeg-91381201f0ed87718477e4fdb903c76289faa175.tar.gz |
theora comments skipping
Originally committed as revision 2361 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/vp3.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c index 315e18566c..c72c7fc164 100644 --- a/libavcodec/vp3.c +++ b/libavcodec/vp3.c @@ -2890,6 +2890,25 @@ static int theora_decode_header(AVCodecContext *avctx, GetBitContext gb) return 0; } +static int theora_decode_comments(AVCodecContext *avctx, GetBitContext gb) +{ + int nb_comments, i, tmp; + + tmp = get_bits(&gb, 32); + while(tmp-=8) + skip_bits(&gb, 8); + + nb_comments = get_bits(&gb, 32); + for (i = 0; i < nb_comments; i++) + { + tmp = get_bits(&gb, 32); + while(tmp-=8) + skip_bits(&gb, 8); + } + + return 0; +} + static int theora_decode_tables(AVCodecContext *avctx, GetBitContext gb) { Vp3DecodeContext *s = avctx->priv_data; @@ -2948,7 +2967,7 @@ static int theora_decode_init(AVCodecContext *avctx) vp3_decode_init(avctx); break; case 0x81: - /* comment */ + theora_decode_comments(avctx, gb); break; case 0x82: theora_decode_tables(avctx, gb); |