Off-by-one error fix

Originally committed as revision 7694 to svn://svn.ffmpeg.org/ffmpeg/trunk
pull/126/head
Kostya Shishkov 18 years ago
parent 5cca6bc3cd
commit 14f3f3a1ad
  1. 4
      libavcodec/vc1.c

@ -1283,8 +1283,8 @@ static int decode_sequence_header_adv(VC1Context *v, GetBitContext *gb)
if(get_bits1(gb)) { //Display Info - decoding is not affected by it if(get_bits1(gb)) { //Display Info - decoding is not affected by it
int w, h, ar = 0; int w, h, ar = 0;
av_log(v->s.avctx, AV_LOG_INFO, "Display extended info:\n"); av_log(v->s.avctx, AV_LOG_INFO, "Display extended info:\n");
w = get_bits(gb, 14); w = get_bits(gb, 14) + 1;
h = get_bits(gb, 14); h = get_bits(gb, 14) + 1;
av_log(v->s.avctx, AV_LOG_INFO, "Display dimensions: %ix%i\n", w, h); av_log(v->s.avctx, AV_LOG_INFO, "Display dimensions: %ix%i\n", w, h);
//TODO: store aspect ratio in AVCodecContext //TODO: store aspect ratio in AVCodecContext
if(get_bits1(gb)) if(get_bits1(gb))

Loading…
Cancel
Save