[Ffmpeg-cvslog] CVS: ffmpeg/libavcodec motion_est.c,1.107,1.108

Michael Niedermayer CVS michael
Mon Aug 1 22:01:44 CEST 2005


Update of /cvsroot/ffmpeg/ffmpeg/libavcodec
In directory mail:/var2/tmp/cvs-serv19656

Modified Files:
	motion_est.c 
Log Message:
fix assertion failure for mpeg2 encoding


Index: motion_est.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/motion_est.c,v
retrieving revision 1.107
retrieving revision 1.108
diff -u -d -r1.107 -r1.108
--- motion_est.c	27 Jul 2005 13:16:35 -0000	1.107
+++ motion_est.c	1 Aug 2005 20:01:41 -0000	1.108
@@ -1891,7 +1891,7 @@
 {
     if(s->me_method>=ME_EPZS){
         int score[8];
-        int i, y, range= s->avctx->me_range;
+        int i, y, range= s->avctx->me_range ? s->avctx->me_range : (INT_MAX/2);
         uint8_t * fcode_tab= s->fcode_tab;
         int best_fcode=-1;
         int best_score=-10000000;
@@ -1914,11 +1914,9 @@
                                      fcode_tab[my + MAX_MV]);
                     int j;
                     
-                    if(range){
                         if(mx >= range || mx < -range || 
                            my >= range || my < -range)
                             continue;
-                    }
                     
                     for(j=0; j<fcode && j<8; j++){
                         if(s->pict_type==B_TYPE || s->current_picture.mc_mb_var[xy] < s->current_picture.mb_var[xy])





More information about the ffmpeg-cvslog mailing list