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

Do not restart mixer on volume change

parent 91307e82
......@@ -111,7 +111,7 @@ void aout_FiltersPlay ( filter_t ** pp_filters, unsigned i_nb_filters, aout_buf
int aout_MixerNew( aout_instance_t * p_aout );
void aout_MixerDelete( aout_instance_t * p_aout );
void aout_MixerRun( aout_instance_t * p_aout );
int aout_MixerMultiplierSet( aout_instance_t * p_aout, float f_multiplier );
void aout_MixerMultiplierSet( aout_instance_t * p_aout, float f_multiplier );
/* From output.c : */
int aout_OutputNew( aout_instance_t * p_aout,
......
......@@ -366,25 +366,9 @@ void aout_MixerRun( aout_instance_t * p_aout )
* Please note that we assume that you own the mixer lock when entering this
* function. This function returns -1 on error.
*****************************************************************************/
int aout_MixerMultiplierSet( aout_instance_t * p_aout, float f_multiplier )
void aout_MixerMultiplierSet( aout_instance_t * p_aout, float f_multiplier )
{
float f_old = p_aout->mixer_multiplier;
bool b_new_mixer = false;
if ( p_aout->p_mixer )
{
aout_MixerDelete( p_aout );
b_new_mixer = true;
}
p_aout->mixer_multiplier = f_multiplier;
if ( b_new_mixer && aout_MixerNew( p_aout ) )
{
p_aout->mixer_multiplier = f_old;
aout_MixerNew( p_aout );
return -1;
}
return 0;
if( p_aout->p_mixer )
p_aout->p_mixer->multiplier = f_multiplier;
}
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