- if( var_Type( p_aout, "audio-filter" ) == 0 )
- {
- var_Create( p_aout, "audio-filter",
- VLC_VAR_STRING | VLC_VAR_DOINHERIT );
- text.psz_string = _("Audio filters");
- var_Change( p_aout, "audio-filter", VLC_VAR_SETTEXT, &text, NULL );
- }
- if( var_Type( p_aout, "audio-visual" ) == 0 )
- {
- var_Create( p_aout, "audio-visual",
- VLC_VAR_STRING | VLC_VAR_DOINHERIT );
- text.psz_string = _("Audio visualizations");
- var_Change( p_aout, "audio-visual", VLC_VAR_SETTEXT, &text, NULL );
- }
-
- if( var_Type( p_aout, "audio-replay-gain-mode" ) == 0 )
- {
- module_config_t *p_config;
- int i;
-
- p_config = config_FindConfig( VLC_OBJECT(p_aout), "audio-replay-gain-mode" );
- if( p_config && p_config->i_list )
- {
- var_Create( p_aout, "audio-replay-gain-mode",
- VLC_VAR_STRING | VLC_VAR_DOINHERIT );
-
- text.psz_string = _("Replay gain");
- var_Change( p_aout, "audio-replay-gain-mode", VLC_VAR_SETTEXT, &text, NULL );
-
- for( i = 0; i < p_config->i_list; i++ )
- {
- val.psz_string = (char *)p_config->ppsz_list[i];
- text.psz_string = (char *)p_config->ppsz_list_text[i];
- var_Change( p_aout, "audio-replay-gain-mode", VLC_VAR_ADDCHOICE,
- &val, &text );
- }
- }
- }
- var_AddCallback( p_aout, "audio-replay-gain-mode", ReplayGainCallback, p_input );
-
- char *gain = var_InheritString (p_aout, "audio-replay-gain-mode");
- vlc_atomic_setf (&p_input->multiplier,
- ReplayGainSelect (VLC_OBJECT(p_aout), gain,
- &p_input->replay_gain));
- free (gain);
-
- if( var_Type( p_aout, "audio-replay-gain-preamp" ) == 0 )
- {
- var_Create( p_aout, "audio-replay-gain-preamp",
- VLC_VAR_FLOAT | VLC_VAR_DOINHERIT );
- }
- if( var_Type( p_aout, "audio-replay-gain-default" ) == 0 )
- {
- var_Create( p_aout, "audio-replay-gain-default",
- VLC_VAR_FLOAT | VLC_VAR_DOINHERIT );
- }
- if( var_Type( p_aout, "audio-replay-gain-peak-protection" ) == 0 )
- {
- var_Create( p_aout, "audio-replay-gain-peak-protection",
- VLC_VAR_BOOL | VLC_VAR_DOINHERIT );
- }
-
- psz_filters = var_GetString( p_aout, "audio-filter" );
- psz_visual = var_GetString( p_aout, "audio-visual");
- psz_scaletempo = var_InheritBool( p_aout, "audio-time-stretch" ) ? strdup( "scaletempo" ) : NULL;