Mercurial > mplayer.hg
changeset 10498:17391ba6c53b
mb decision stuff
author | michael |
---|---|
date | Tue, 29 Jul 2003 02:29:58 +0000 |
parents | 9e6becbd5c8a |
children | 9d9db4e8fd17 |
files | DOCS/en/mplayer.1 libmpcodecs/ve_lavc.c |
diffstat | 2 files changed, 22 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/DOCS/en/mplayer.1 Mon Jul 28 20:04:09 2003 +0000 +++ b/DOCS/en/mplayer.1 Tue Jul 29 02:29:58 2003 +0000 @@ -3358,10 +3358,19 @@ .RE .PD 1 .TP -.B vhq\ \ \ \ -high quality mode, encode each macro block in all modes and choose the best. +.B mbd=<0\-2> +macoblock decision algo (high quality mode), encode each macro block in all modes and choose the best. This is slow but results in better quality and file size. -(default: disabled) +.PD 0 +.RSs +.IPs 0 +use mbcmp (default) +.IPs 1 +select the MB mode which needs the fewest bits (=vhq) +.IPs 2 +select the MB mode which has the best rate distortion +.RE +.PD 1 .TP .B v4mv\ \ \ Allow 4 motion vectors per macroblock (slightly better quality).
--- a/libmpcodecs/ve_lavc.c Mon Jul 28 20:04:09 2003 +0000 +++ b/libmpcodecs/ve_lavc.c Tue Jul 29 02:29:58 2003 +0000 @@ -55,7 +55,7 @@ static char *lavc_param_vcodec = "mpeg4"; static int lavc_param_vbitrate = -1; static int lavc_param_vrate_tolerance = 1000*8; -static int lavc_param_vhq = 0; /* default is realtime encoding */ +static int lavc_param_mb_decision = 0; /* default is realtime encoding */ static int lavc_param_v4mv = 0; static int lavc_param_vme = 4; static int lavc_param_vqscale = 0; @@ -135,7 +135,8 @@ {"vcodec", &lavc_param_vcodec, CONF_TYPE_STRING, 0, 0, 0, NULL}, {"vbitrate", &lavc_param_vbitrate, CONF_TYPE_INT, CONF_RANGE, 4, 24000000, NULL}, {"vratetol", &lavc_param_vrate_tolerance, CONF_TYPE_INT, CONF_RANGE, 4, 24000000, NULL}, - {"vhq", &lavc_param_vhq, CONF_TYPE_FLAG, 0, 0, 1, NULL}, + {"vhq", &lavc_param_mb_decision, CONF_TYPE_FLAG, 0, 0, 1, NULL}, + {"mbd", &lavc_param_mb_decision, CONF_TYPE_INT, CONF_RANGE, 0, 9, NULL}, {"v4mv", &lavc_param_v4mv, CONF_TYPE_FLAG, 0, 0, 1, NULL}, {"vme", &lavc_param_vme, CONF_TYPE_INT, CONF_RANGE, 0, 5, NULL}, {"vqscale", &lavc_param_vqscale, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL}, @@ -386,13 +387,16 @@ else lavc_venc_context->gop_size = 250; /* default */ - if (lavc_param_vhq) + lavc_venc_context->flags = 0; + if (lavc_param_mb_decision) { printf("High quality encoding selected (non real time)!\n"); - lavc_venc_context->flags = CODEC_FLAG_HQ; +#if LIBAVCODEC_BUILD < 4673 + lavc_venc_context->flags = CODEC_FLAG_HQ; +#else + lavc_venc_context->mb_decision= lavc_param_mb_decision; +#endif } - else - lavc_venc_context->flags = 0; #if LIBAVCODEC_BUILD >= 4647 lavc_venc_context->me_cmp= lavc_param_me_cmp;