Commit a64b15e7 authored by Ilkka Ollakka's avatar Ilkka Ollakka

avcodec: Allow encoding standard stricted to be from -2 to 2

Should fix #6184 as aac encoding seems to require --sout-ffmpeg-strict=-2
parent 1ff2b3fb
......@@ -182,6 +182,7 @@ vlc_module_begin ()
ENC_QSCALE_TEXT, ENC_QSCALE_LONGTEXT, true )
add_integer( ENC_CFG_PREFIX "strict", 0,
ENC_STRICT_TEXT, ENC_STRICT_LONGTEXT, true )
change_integer_range( -2, 2 )
add_float( ENC_CFG_PREFIX "lumi-masking", 0.0,
ENC_LUMI_MASKING_TEXT, ENC_LUMI_MASKING_LONGTEXT, true )
add_float( ENC_CFG_PREFIX "dark-masking", 0.0,
......
......@@ -226,7 +226,7 @@ int ffmpeg_OpenCodec( decoder_t *p_dec );
#define ENC_STRICT_TEXT N_( "Strict standard compliance" )
#define ENC_STRICT_LONGTEXT N_( "Force a strict standard " \
"compliance when encoding (accepted values: -1, 0, 1)." )
"compliance when encoding (accepted values: -2 to 2)." )
#define ENC_LUMI_MASKING_TEXT N_( "Luminance masking" )
#define ENC_LUMI_MASKING_LONGTEXT N_( "Raise the quantizer for " \
......
......@@ -382,9 +382,7 @@ int OpenEncoder( vlc_object_t *p_this )
p_sys->i_qmax = var_GetInteger( p_enc, ENC_CFG_PREFIX "qmax" );
p_sys->b_trellis = var_GetBool( p_enc, ENC_CFG_PREFIX "trellis" );
i_val = var_GetInteger( p_enc, ENC_CFG_PREFIX "strict" );
if( i_val < - 1 || i_val > 1 ) i_val = 0;
p_context->strict_std_compliance = i_val;
p_context->strict_std_compliance = var_GetInteger( p_enc, ENC_CFG_PREFIX "strict" );
p_sys->f_lumi_masking = var_GetFloat( p_enc, ENC_CFG_PREFIX "lumi-masking" );
p_sys->f_dark_masking = var_GetFloat( p_enc, ENC_CFG_PREFIX "dark-masking" );
......
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