Mercurial > mplayer.hg
diff mencoder.c @ 4408:291832d8d984
added constant-qscale encoding support with lavc, fixed slightly incorrect definition for the vme lavc option
author | rfelker |
---|---|
date | Tue, 29 Jan 2002 16:27:21 +0000 |
parents | 817530449706 |
children | 6310422b9557 |
line wrap: on
line diff
--- a/mencoder.c Tue Jan 29 12:11:52 2002 +0000 +++ b/mencoder.c Tue Jan 29 16:27:21 2002 +0000 @@ -72,6 +72,7 @@ int lavc_param_vbitrate = -1; int lavc_param_vhq = 0; /* default is realtime encoding */ int lavc_param_vme = 3; +int lavc_param_vqscale = 0; int lavc_param_keyint = -1; #endif @@ -988,11 +989,13 @@ encoder context - FIXME */ motion_estimation_method = lavc_param_vme; -#if 0 /* fixed qscale :p */ - lavc_venc_context.flags |= CODEC_FLAG_QSCALE; - lavc_venc_context.quality = 1; -#endif + if (lavc_param_vqscale) + { + printf("Using constant qscale = %d (VBR)\n", lavc_param_vqscale); + lavc_venc_context.flags |= CODEC_FLAG_QSCALE; + lavc_venc_context.quality = lavc_param_vqscale; + } if (avcodec_open(&lavc_venc_context, lavc_venc_codec) != 0) {