From 84c8d4b689168335da090bae57f4a162ee10018d Mon Sep 17 00:00:00 2001 From: Max Horn Date: Fri, 26 Jul 2002 00:41:07 +0000 Subject: added painelf's (still unfinished) sound dialog in NewGUI. Beware, this is work in progress, don't report problems with it just yet, we already know they are there :-) svn-id: r4635 --- sound/imuse.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'sound') diff --git a/sound/imuse.cpp b/sound/imuse.cpp index 677a5c79f2..8e0e99e099 100644 --- a/sound/imuse.cpp +++ b/sound/imuse.cpp @@ -1255,6 +1255,9 @@ int IMuseInternal::get_music_volume() int IMuseInternal::set_music_volume(uint vol) { + // recalibrate from 0-255 range + vol = vol * 100 / 255; + if (vol > 100) vol = 100; else if (vol < 1) @@ -1267,6 +1270,10 @@ int IMuseInternal::set_music_volume(uint vol) int IMuseInternal::set_master_volume(uint vol) { int i; + + // recalibrate from 0-255 range + vol = vol * 127 / 255; + if (vol > 127) return -1; -- cgit v1.2.3