MCPcopy Create free account
hub / github.com/AppleWin/AppleWin / SpkrSetVolume

Function SpkrSetVolume

source/Speaker.cpp:858–869  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

856}
857
858void SpkrSetVolume(uint32_t dwVolume, uint32_t dwVolumeMax)
859{
860 SpeakerVoice.dwUserVolume = dwVolume;
861
862 SpeakerVoice.nVolume = NewVolume(dwVolume, dwVolumeMax);
863
864 if (SpeakerVoice.bActive && !SpeakerVoice.bMute)
865 {
866 HRESULT hr = SpeakerVoice.lpDSBvoice->SetVolume(SpeakerVoice.nVolume);
867 LogFileOutput("SpkrSetVolume: SetVolume(%d) res = %08X\n", SpeakerVoice.nVolume, hr);
868 }
869}
870
871//=============================================================================
872

Callers 2

LoadConfigurationFunction · 0.85
ApplyConfigAfterCloseMethod · 0.85

Calls 3

NewVolumeFunction · 0.85
LogFileOutputFunction · 0.85
SetVolumeMethod · 0.45

Tested by

no test coverage detected