aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/motion_est.c
diff options
context:
space:
mode:
authorDiego Biurrun <diego@biurrun.de>2012-09-24 17:57:14 +0200
committerDiego Biurrun <diego@biurrun.de>2013-01-06 16:30:02 +0100
commita0c5917f86a6ff0d91d7f9af71afca0d43c14825 (patch)
treeb19038067509686714ad008a4b8389ad57ad8ec8 /libavcodec/motion_est.c
parent6b8d88808dbc21197281ff4ea5a4660ad19e1bf3 (diff)
downloadffmpeg-a0c5917f86a6ff0d91d7f9af71afca0d43c14825.tar.gz
Drop Snow codec
Snow is a toy codec with no real-world use and horrible code.
Diffstat (limited to 'libavcodec/motion_est.c')
-rw-r--r--libavcodec/motion_est.c21
1 files changed, 10 insertions, 11 deletions
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;