diff options
author | Anton Khirnov <anton@khirnov.net> | 2013-11-30 11:10:53 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2013-12-05 13:23:03 +0100 |
commit | 1f8eb69079880ef1f394c498dfdf471f91222a06 (patch) | |
tree | 4577deca8f75af499d073c5e6b884c26831e22a3 /libavcodec/mpegvideo.c | |
parent | bedf952bb80ae26427854dcde56c139ecb87d4a0 (diff) | |
download | ffmpeg-1f8eb69079880ef1f394c498dfdf471f91222a06.tar.gz |
mpegvideo: move encoding-only initialization from common_init() to encode_init()
Diffstat (limited to 'libavcodec/mpegvideo.c')
-rw-r--r-- | libavcodec/mpegvideo.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c index 74095affb3..782185f73a 100644 --- a/libavcodec/mpegvideo.c +++ b/libavcodec/mpegvideo.c @@ -1037,37 +1037,6 @@ av_cold int ff_MPV_common_init(MpegEncContext *s) s->stream_codec_tag = avpriv_toupper4(s->avctx->stream_codec_tag); - if (s->width && s->height) { - s->avctx->coded_frame = &s->current_picture.f; - - if (s->encoding) { - if (s->msmpeg4_version) { - FF_ALLOCZ_OR_GOTO(s->avctx, s->ac_stats, - 2 * 2 * (MAX_LEVEL + 1) * - (MAX_RUN + 1) * 2 * sizeof(int), fail); - } - FF_ALLOCZ_OR_GOTO(s->avctx, s->avctx->stats_out, 256, fail); - - FF_ALLOCZ_OR_GOTO(s->avctx, s->q_intra_matrix, - 64 * 32 * sizeof(int), fail); - FF_ALLOCZ_OR_GOTO(s->avctx, s->q_inter_matrix, - 64 * 32 * sizeof(int), fail); - FF_ALLOCZ_OR_GOTO(s->avctx, s->q_intra_matrix16, - 64 * 32 * 2 * sizeof(uint16_t), fail); - FF_ALLOCZ_OR_GOTO(s->avctx, s->q_inter_matrix16, - 64 * 32 * 2 * sizeof(uint16_t), fail); - FF_ALLOCZ_OR_GOTO(s->avctx, s->input_picture, - MAX_PICTURE_COUNT * sizeof(Picture *), fail); - FF_ALLOCZ_OR_GOTO(s->avctx, s->reordered_input_picture, - MAX_PICTURE_COUNT * sizeof(Picture *), fail); - - if (s->avctx->noise_reduction) { - FF_ALLOCZ_OR_GOTO(s->avctx, s->dct_offset, - 2 * 64 * sizeof(uint16_t), fail); - } - } - } - FF_ALLOCZ_OR_GOTO(s->avctx, s->picture, MAX_PICTURE_COUNT * sizeof(Picture), fail); for (i = 0; i < MAX_PICTURE_COUNT; i++) { |