Commit b8ef86cc authored by Ilkka Ollakka's avatar Ilkka Ollakka

avcodec: use qscale=3 as default if videobitrate isn't provided

If user doesn't give videobitrate use some reasonable default to get ok output
from avcodec transcode (for example mpeg4 video).

(cherry picked from commit 20f32dd168a37dde277edae8aee90906e79dcef4)
Signed-off-by: default avatarIlkka Ollakka <ileoo@videolan.org>
parent c3d4352c
......@@ -215,7 +215,7 @@ vlc_module_begin ()
ENC_QMAX_TEXT, ENC_QMAX_LONGTEXT, true )
add_bool( ENC_CFG_PREFIX "trellis", false,
ENC_TRELLIS_TEXT, ENC_TRELLIS_LONGTEXT, true )
add_float( ENC_CFG_PREFIX "qscale", 0,
add_float( ENC_CFG_PREFIX "qscale", 3,
ENC_QSCALE_TEXT, ENC_QSCALE_LONGTEXT, true )
add_integer( ENC_CFG_PREFIX "strict", 0,
ENC_STRICT_TEXT, ENC_STRICT_LONGTEXT, true )
......
......@@ -627,7 +627,7 @@ int OpenEncoder( vlc_object_t *p_this )
p_context->mb_decision = p_sys->i_hq;
if( p_sys->i_quality )
if( p_sys->i_quality && !p_enc->fmt_out.i_bitrate )
{
p_context->flags |= CODEC_FLAG_QSCALE;
p_context->global_quality = p_sys->i_quality;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment