diff --git a/win32/CWaveOut.cpp b/win32/CWaveOut.cpp index a1765905..8a27f104 100644 --- a/win32/CWaveOut.cpp +++ b/win32/CWaveOut.cpp @@ -75,7 +75,8 @@ bool CWaveOut::SetupSound() void CWaveOut::SetVolume(double volume) { - waveOutSetVolume(hWaveOut, (DWORD)(volume * 0xffffffff)); + uint32 volumeout = volume * 0xffff; + waveOutSetVolume(hWaveOut, volumeout + (volumeout << 16); } void CWaveOut::BeginPlayback()