Commit e065ea97 authored by Thomas Guillem's avatar Thomas Guillem

mmdevice: report new volume after its modification (if any)

parent 06de92ac
......@@ -971,12 +971,6 @@ static HRESULT MMSession(audio_output_t *aout, IMMDeviceEnumerator *it)
{
float level;
hr = ISimpleAudioVolume_GetMasterVolume(volume, &level);
if (SUCCEEDED(hr))
aout_VolumeReport(aout, cbrtf(level * sys->gain));
else
msg_Err(aout, "cannot get master volume (error 0x%lx)", hr);
level = sys->requested_volume;
if (level >= 0.f)
{
......@@ -987,6 +981,12 @@ static HRESULT MMSession(audio_output_t *aout, IMMDeviceEnumerator *it)
}
sys->requested_volume = -1.f;
hr = ISimpleAudioVolume_GetMasterVolume(volume, &level);
if (SUCCEEDED(hr))
aout_VolumeReport(aout, cbrtf(level * sys->gain));
else
msg_Err(aout, "cannot get master volume (error 0x%lx)", hr);
BOOL mute;
hr = ISimpleAudioVolume_GetMute(volume, &mute);
......
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