From a0c5917f86a6ff0d91d7f9af71afca0d43c14825 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Mon, 24 Sep 2012 17:57:14 +0200 Subject: Drop Snow codec Snow is a toy codec with no real-world use and horrible code. --- libavcodec/motion_est.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'libavcodec/motion_est.c') diff --git a/libavcodec/motion_est.c b/libavcodec/motion_est.c index 3577ada50c..9cf1203be0 100644 --- a/libavcodec/motion_est.c +++ b/libavcodec/motion_est.c @@ -302,8 +302,9 @@ int ff_init_me(MpegEncContext *s){ av_log(s->avctx, AV_LOG_ERROR, "ME_MAP size is too small for SAB diamond\n"); return -1; } - //special case of snow is needed because snow uses its own iterative ME code - if(s->me_method!=ME_ZERO && s->me_method!=ME_EPZS && s->me_method!=ME_X1 && s->avctx->codec_id != AV_CODEC_ID_SNOW){ + if (s->me_method != ME_ZERO && + s->me_method != ME_EPZS && + s->me_method != ME_X1) { av_log(s->avctx, AV_LOG_ERROR, "me_method is only allowed to be set to zero and epzs; for hex,umh,full and others see dia_size\n"); return -1; } @@ -354,16 +355,14 @@ int ff_init_me(MpegEncContext *s){ /* 8x8 fullpel search would need a 4x4 chroma compare, which we do * not have yet, and even if we had, the motion estimation code * does not expect it. */ - if(s->codec_id != AV_CODEC_ID_SNOW){ - if((c->avctx->me_cmp&FF_CMP_CHROMA)/* && !s->dsp.me_cmp[2]*/){ - s->dsp.me_cmp[2]= zero_cmp; - } - if((c->avctx->me_sub_cmp&FF_CMP_CHROMA) && !s->dsp.me_sub_cmp[2]){ - s->dsp.me_sub_cmp[2]= zero_cmp; - } - c->hpel_put[2][0]= c->hpel_put[2][1]= - c->hpel_put[2][2]= c->hpel_put[2][3]= zero_hpel; + if((c->avctx->me_cmp&FF_CMP_CHROMA)/* && !s->dsp.me_cmp[2]*/){ + s->dsp.me_cmp[2]= zero_cmp; + } + if((c->avctx->me_sub_cmp&FF_CMP_CHROMA) && !s->dsp.me_sub_cmp[2]){ + s->dsp.me_sub_cmp[2]= zero_cmp; } + c->hpel_put[2][0]= c->hpel_put[2][1]= + c->hpel_put[2][2]= c->hpel_put[2][3]= zero_hpel; if(s->codec_id == AV_CODEC_ID_H261){ c->sub_motion_search= no_sub_motion_search; -- cgit v1.2.3