Commit e512e5be authored by Gildas Bazin's avatar Gildas Bazin

* src/libvlc.h, src/input/: new --clock-synchro option to enable/disable the...

* src/libvlc.h, src/input/: new --clock-synchro option to enable/disable the input clock synchronisation algorithm.
parent 28a41f12
...@@ -2036,6 +2036,10 @@ static int InputSourceInit( input_thread_t *p_input, ...@@ -2036,6 +2036,10 @@ static int InputSourceInit( input_thread_t *p_input,
} }
} }
} }
if( var_GetInteger( p_input, "clock-synchro" ) != -1 )
in->b_can_pace_control = !var_GetInteger( p_input, "clock-synchro" );
free( psz_dup ); free( psz_dup );
return VLC_SUCCESS; return VLC_SUCCESS;
...@@ -2311,7 +2315,8 @@ static void ParseOption( input_thread_t *p_input, const char *psz_option ) ...@@ -2311,7 +2315,8 @@ static void ParseOption( input_thread_t *p_input, const char *psz_option )
var_Set( p_input, psz_name, val ); var_Set( p_input, psz_name, val );
msg_Dbg( p_input, "set input option: %s to %s", psz_name, psz_value ? psz_value : ( val.b_bool ? "true" : "false") ); msg_Dbg( p_input, "set input option: %s to %s", psz_name,
psz_value ? psz_value : ( val.b_bool ? "true" : "false") );
cleanup: cleanup:
if( psz_name ) free( psz_name ); if( psz_name ) free( psz_name );
......
...@@ -431,6 +431,7 @@ void input_ConfigVarInit ( input_thread_t *p_input ) ...@@ -431,6 +431,7 @@ void input_ConfigVarInit ( input_thread_t *p_input )
var_Create( p_input, "audio-desync", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT ); var_Create( p_input, "audio-desync", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT );
var_Create( p_input, "cr-average", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT ); var_Create( p_input, "cr-average", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT );
var_Create( p_input, "clock-synchro", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT);
var_Create( p_input, "seekable", VLC_VAR_BOOL ); var_Create( p_input, "seekable", VLC_VAR_BOOL );
val.b_bool = VLC_TRUE; /* Fixed later*/ val.b_bool = VLC_TRUE; /* Fixed later*/
......
...@@ -288,6 +288,14 @@ static char *ppsz_align_descriptions[] = ...@@ -288,6 +288,14 @@ static char *ppsz_align_descriptions[] =
"When using the PVR input (or a very irregular source), you should " \ "When using the PVR input (or a very irregular source), you should " \
"set this to 10000.") "set this to 10000.")
#define CLOCK_SYNCHRO_TEXT N_("Clock synchronisation")
#define CLOCK_SYNCHRO_LONGTEXT N_( \
"Allows you to enable/disable the input clock synchronisation for " \
"real-time sources.")
static int pi_clock_values[] = { -1, 0, 1 };
static char *ppsz_clock_descriptions[] =
{ N_("Default"), N_("Disable"), N_("Enable") };
#define SERVER_PORT_TEXT N_("UDP port") #define SERVER_PORT_TEXT N_("UDP port")
#define SERVER_PORT_LONGTEXT N_( \ #define SERVER_PORT_LONGTEXT N_( \
"This is the port used for UDP streams. By default, we chose 1234.") "This is the port used for UDP streams. By default, we chose 1234.")
...@@ -1062,6 +1070,9 @@ vlc_module_begin(); ...@@ -1062,6 +1070,9 @@ vlc_module_begin();
add_integer( "cr-average", 40, NULL, CR_AVERAGE_TEXT, add_integer( "cr-average", 40, NULL, CR_AVERAGE_TEXT,
CR_AVERAGE_LONGTEXT, VLC_FALSE ); CR_AVERAGE_LONGTEXT, VLC_FALSE );
add_integer( "clock-synchro", -1, NULL, CLOCK_SYNCHRO_TEXT,
CLOCK_SYNCHRO_LONGTEXT, VLC_FALSE );
change_integer_list( pi_clock_values, ppsz_clock_descriptions, 0 );
/* Decoder options */ /* Decoder options */
add_category_hint( N_("Decoders"), CODEC_CAT_LONGTEXT , VLC_TRUE ); add_category_hint( N_("Decoders"), CODEC_CAT_LONGTEXT , VLC_TRUE );
......
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