diff --git a/libavcodec/mpeg4video.h b/libavcodec/mpeg4video.h index 60857cce116259557e2f57a9b3de1c6eb9381b56..6a143e1eb4199008d3fc59357c5b0ddac2ef05e7 100644 --- a/libavcodec/mpeg4video.h +++ b/libavcodec/mpeg4video.h @@ -73,6 +73,8 @@ typedef struct Mpeg4DecContext { ///< time distance of first I -> B, used for interlaced b frames int t_frame; + int new_pred; + /* bug workarounds */ int divx_version; int divx_build; diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c index e2ad7941ebd9e6d4e1bdb9e403d63079ad4b5aa6..b1bcd38e07143e4f3eec34dd41de198e24766e54 100644 --- a/libavcodec/mpeg4videodec.c +++ b/libavcodec/mpeg4videodec.c @@ -1940,8 +1940,8 @@ no_cplx_est: ctx->rvlc = get_bits1(gb); if (vo_ver_id != 1) { - s->new_pred = get_bits1(gb); - if (s->new_pred) { + ctx->new_pred = get_bits1(gb); + if (ctx->new_pred) { av_log(s->avctx, AV_LOG_ERROR, "new pred not supported\n"); skip_bits(gb, 2); /* requested upstream message type */ skip_bits1(gb); /* newpred segment type */ @@ -1950,7 +1950,7 @@ no_cplx_est: av_log(s->avctx, AV_LOG_ERROR, "reduced resolution VOP not supported\n"); } else { - s->new_pred = 0; + ctx->new_pred = 0; } s->scalability = get_bits1(gb); diff --git a/libavcodec/mpegvideo.h b/libavcodec/mpegvideo.h index 3d4e26d5427b381bc81b65b394a691323bcf25dc..8dbded98dfeff9ec22991f724f1f0212533bcf2b 100644 --- a/libavcodec/mpegvideo.h +++ b/libavcodec/mpegvideo.h @@ -592,7 +592,6 @@ typedef struct MpegEncContext { int scalability; int hierachy_type; int enhancement_type; - int new_pred; int aspect_ratio_info; //FIXME remove int sprite_warping_accuracy; int data_partitioning; ///< data partitioning flag from header