fixed back->front channel bar desync

This commit is contained in:
Hane 2023-08-17 12:40:32 +02:00
commit b15e5d6df7
4 changed files with 22 additions and 12 deletions

View file

@ -80,10 +80,10 @@ std::wstring Endpoint::getName(){
float Endpoint::getVolume(int channel){
float volume;
if (channel == ENDPOINT_MASTER_VOLUME) {
if(FAILED(endpointVolume->GetMasterVolumeLevelScalar(&volume))) { log_debugcpp("si");}
if (channel == AudioChannel::CHANNEL_MAIN) {
if(FAILED(endpointVolume->GetMasterVolumeLevelScalar(&volume))) { /* log_debugcpp("si") */;}
} else {
if(FAILED(endpointVolume->GetChannelVolumeLevelScalar(channel, &volume))) { log_debugcpp("si");}
if(FAILED(endpointVolume->GetChannelVolumeLevelScalar(channel, &volume))) { /* log_debugcpp("si"); */}
}
return volume;
}