Commit 19ccbcb3 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

aout: remove unused "equalizer" object variable

This is no longer set anywhere, since equalizer-preset superseded it.
parent 0929da45
......@@ -315,8 +315,6 @@ static int EqualizerCallback (vlc_object_t *obj, const char *var,
void *data)
{
const char *val = newval.psz_string;
if (!strcmp("equalizer", var) && *val)
var_SetString (obj, "equalizer-preset", val);
if (aout_ChangeFilterString (obj, obj, "audio-filter", "equalizer", *val))
aout_InputRequestRestart ((audio_output_t *)obj); /* <- That sucks! */
......@@ -416,7 +414,6 @@ aout_filters_t *aout_FiltersNew (vlc_object_t *obj,
/* Callbacks (before reading values and also before return statement) */
if (request_vout != NULL)
{
var_AddCallback (obj, "equalizer", EqualizerCallback, NULL);
var_AddCallback (obj, "equalizer-bands", EqualizerCallback, NULL);
var_AddCallback (obj, "visual", VisualizationCallback, NULL);
......@@ -496,7 +493,6 @@ aout_filters_t *aout_FiltersNew (vlc_object_t *obj,
error:
aout_FiltersPipelineDestroy (filters->tab, filters->count);
var_DelCallback (obj, "equalizer", EqualizerCallback, NULL);
var_DelCallback (obj, "equalizer-bands", EqualizerCallback, NULL);
var_DelCallback (obj, "visual", VisualizationCallback, NULL);
free (filters);
......@@ -519,7 +515,6 @@ void aout_FiltersDelete (vlc_object_t *obj, aout_filters_t *filters)
aout_FiltersPipelineDestroy (filters->tab, filters->count);
if (obj != NULL)
{
var_DelCallback (obj, "equalizer", EqualizerCallback, NULL);
var_DelCallback (obj, "equalizer-bands", EqualizerCallback, NULL);
var_DelCallback (obj, "visual", VisualizationCallback, NULL);
}
......
......@@ -266,22 +266,6 @@ audio_output_t *aout_New (vlc_object_t *parent)
free (str);
}
/* Equalizer */
var_Create (aout, "equalizer", VLC_VAR_STRING | VLC_VAR_HASCHOICE);
text.psz_string = _("Equalizer");
var_Change (aout, "equalizer", VLC_VAR_SETTEXT, &text, NULL);
val.psz_string = (char*)"";
text.psz_string = _("Disable");
var_Change (aout, "equalizer", VLC_VAR_ADDCHOICE, &val, &text);
cfg = config_FindConfig (VLC_OBJECT(aout), "equalizer-preset");
if (likely(cfg != NULL))
for (unsigned i = 0; i < cfg->list_count; i++)
{
val.psz_string = cfg->list.psz[i];
text.psz_string = vlc_gettext(cfg->list_text[i]);
var_Change (aout, "equalizer", VLC_VAR_ADDCHOICE, &val, &text);
}
var_Create (aout, "audio-filter", VLC_VAR_STRING | VLC_VAR_DOINHERIT);
text.psz_string = _("Audio filters");
var_Change (aout, "audio-filter", VLC_VAR_SETTEXT, &text, NULL);
......@@ -306,8 +290,10 @@ audio_output_t *aout_New (vlc_object_t *parent)
&val, &text);
}
/* Equalizer */
var_Create (aout, "equalizer-preamp", VLC_VAR_FLOAT | VLC_VAR_DOINHERIT);
var_Create (aout, "equalizer-bands", VLC_VAR_STRING | VLC_VAR_DOINHERIT);
var_Create (aout, "equalizer-preset", VLC_VAR_STRING | VLC_VAR_DOINHERIT);
return aout;
}
......
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