Index: DOCS/man/en/mplayer.1 =================================================================== RCS file: /cvsroot/mplayer/main/DOCS/man/en/mplayer.1,v retrieving revision 1.1281 diff -u -r1.1281 mplayer.1 --- DOCS/man/en/mplayer.1 1 May 2006 17:08:52 -0000 1.1281 +++ DOCS/man/en/mplayer.1 13 May 2006 16:44:26 -0000 @@ -7857,6 +7857,21 @@ This has no effect if mbd=0. . .TP +.B mv0_threshold= +When surrounding motion vectors are <0,0> and the motion estimation +score of the current block is less than mv0_threshold, <0,0> is used for +the motion vector and further motion estimation is skipped (default: +256). +Lowering mv0_threshold to 0 can give a slight (0.01dB) PSNR increase and +possibly make the encoded video look slightly better; raising +mv0_threshold past 320 results in diminished PSNR and visual quality. +Higher values speed up encoding very slightly (usually less than 1%, +depending on the other options used). +.br +.I NOTE: +This option does not require mv0 to be enabled. +. +.TP .B qprd (mbd=2 only) rate distorted optimal quantization parameter (QP) for the given lambda of each macroblock Index: libmpcodecs/ve_lavc.c =================================================================== RCS file: /cvsroot/mplayer/main/libmpcodecs/ve_lavc.c,v retrieving revision 1.138 diff -u -r1.138 ve_lavc.c --- libmpcodecs/ve_lavc.c 31 Mar 2006 00:15:47 -0000 1.138 +++ libmpcodecs/ve_lavc.c 13 May 2006 16:44:26 -0000 @@ -160,6 +160,7 @@ static int lavc_param_bidir_refine = 0; static int lavc_param_sc_factor = 1; static int lavc_param_video_global_header= 0; +static int lavc_param_mv0_threshold = 256; char *lavc_param_acodec = "mp2"; int lavc_param_atag = 0; @@ -319,6 +320,7 @@ {"sc_factor", &lavc_param_sc_factor, CONF_TYPE_INT, CONF_RANGE, 1, INT_MAX, NULL}, {"vglobal", &lavc_param_video_global_header, CONF_TYPE_INT, CONF_RANGE, 0, INT_MAX, NULL}, {"aglobal", &lavc_param_audio_global_header, CONF_TYPE_INT, CONF_RANGE, 0, INT_MAX, NULL}, + {"mv0_threshold", &lavc_param_mv0_threshold, CONF_TYPE_INT, CONF_RANGE, 0, INT_MAX, NULL}, {NULL, NULL, 0, 0, 0, 0, NULL} }; #endif @@ -649,6 +651,7 @@ if(lavc_param_video_global_header&2){ lavc_venc_context->flags2 |= CODEC_FLAG2_LOCAL_HEADER; } + lavc_venc_context->mv0_threshold = lavc_param_mv0_threshold; switch(lavc_param_format) {