[x264-devel] commit: Limit MVrange correctly in interlaced mode (Jason Garrett-Glaser )

git version control git at videolan.org
Sat Jul 12 22:10:57 CEST 2008


x264 | branch: master | Jason Garrett-Glaser <darkshikari at gmail.com> | Sat Jul 12 14:10:38 2008 -0600| [8a440db9296cf374b0599313aa5876c22c98524b]

Limit MVrange correctly in interlaced mode
Bug report by Sigma Designs, Inc.

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=8a440db9296cf374b0599313aa5876c22c98524b
---

 encoder/encoder.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/encoder/encoder.c b/encoder/encoder.c
index 8f1ebac..fb34ca8 100644
--- a/encoder/encoder.c
+++ b/encoder/encoder.c
@@ -504,9 +504,9 @@ static int x264_validate_parameters( x264_t *h )
             return -1;
         }
         if( h->param.analyse.i_mv_range <= 0 )
-            h->param.analyse.i_mv_range = l->mv_range;
+            h->param.analyse.i_mv_range = l->mv_range >> h->param.b_interlaced;
         else
-            h->param.analyse.i_mv_range = x264_clip3(h->param.analyse.i_mv_range, 32, 512);
+            h->param.analyse.i_mv_range = x264_clip3(h->param.analyse.i_mv_range, 32, 512 >> h->param.b_interlaced);
         if( h->param.analyse.i_direct_8x8_inference < 0 )
             h->param.analyse.i_direct_8x8_inference = l->direct8x8;
     }



More information about the x264-devel mailing list