aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README3
-rw-r--r--TODO3
-rw-r--r--base/gameDetector.cpp6
-rw-r--r--doc/05_01.tex1
-rw-r--r--doc/08.tex2
-rw-r--r--gui/launcher.cpp3
-rw-r--r--gui/options.cpp28
-rw-r--r--gui/options.h3
-rw-r--r--queen/queen.cpp1
-rw-r--r--saga/music.cpp2
-rw-r--r--scumm/scumm.cpp7
-rw-r--r--scummvm.64
12 files changed, 9 insertions, 54 deletions
diff --git a/README b/README
index 1ebf6c0d02..91b683643f 100644
--- a/README
+++ b/README
@@ -316,7 +316,6 @@ arguments - see the next section.
-e, --music-driver=MODE Select music driver (see also section 7.0)
-q, --language=LANG Select language (see also section 5.2)
-m, --music-volume=NUM Set the music volume, 0-255 (default: 192)
- -o, --master-volume=NUM Set the master volume, 0-255 (default: 192)
-s, --sfx-volume=NUM Set the sfx volume, 0-255 (default: 192)
-r, --speech-volume=NUM Set the voice volume, 0-255 (default: 192)
-n, --subtitles Enable subtitles (use with games that have voice)
@@ -990,7 +989,6 @@ An example config file looks as follows:
[tentacle]
path=C:\tentacle\
subtitles=true
- master_volume=98
music_volume=40
sfx_volume=255
@@ -1037,7 +1035,6 @@ The following keywords are recognized:
cdrom number Number of CD-ROM unit to use for audio. If
negative, don't even try to access the CD-ROM.
joystick_num number Number of joystick device to use for input
- master_volume number The master volume setting (0-255)
music_driver string The music engine to use.
output_rate number The output sample rate to use, in Hz. Sensible
values are 11025, 22050 and 44100.
diff --git a/TODO b/TODO
index 439922d8b7..36ecd41f8b 100644
--- a/TODO
+++ b/TODO
@@ -160,9 +160,6 @@ Audio
=====
* Get the high quality resample code to work
[Fingolfin has started work on this]
-* Consider getting completely rid of the "master volume" (the config key,
- the command line switch, in the GUI, and in the engines), it doesn't
- seem to serve much of a purpose.
* Add "sound types" to the mixer; client code will be able to pass such a type
whenever registering an audio stream. Then, volume control will be changed
to be based on the sound type.
diff --git a/base/gameDetector.cpp b/base/gameDetector.cpp
index f589d9522a..bbee79d7f2 100644
--- a/base/gameDetector.cpp
+++ b/base/gameDetector.cpp
@@ -70,7 +70,6 @@ static const char USAGE_STRING[] =
" -q, --language=LANG Select language (en,de,fr,it,pt,es,jp,zh,kr,se,gb,\n"
" hb,ru,cz)\n"
" -m, --music-volume=NUM Set the music volume, 0-255 (default: 192)\n"
- " -o, --master-volume=NUM Set the master volume, 0-255 (default: 192)\n"
" -s, --sfx-volume=NUM Set the sfx volume, 0-255 (default: 192)\n"
" -r, --speech-volume=NUM Set the speech volume, 0-255 (default: 192)\n"
" -n, --subtitles Enable subtitles (use with games that have voice)\n"
@@ -118,7 +117,6 @@ GameDetector::GameDetector() {
ConfMan.registerDefault("gfx_mode", "normal");
// Sound & Music
- ConfMan.registerDefault("master_volume", 192);
ConfMan.registerDefault("music_volume", 192);
ConfMan.registerDefault("sfx_volume", 192);
ConfMan.registerDefault("speech_volume", 192);
@@ -394,10 +392,6 @@ void GameDetector::parseCommandLine(int argc, char **argv) {
ConfMan.set("subtitles", cmdValue, kTransientDomain);
END_OPTION
- DO_OPTION('o', "master-volume")
- ConfMan.set("master_volume", (int)strtol(option, 0, 10), kTransientDomain);
- END_OPTION
-
DO_OPTION('p', "path")
// TODO: Verify whether the path is valid
ConfMan.set("path", option, kTransientDomain);
diff --git a/doc/05_01.tex b/doc/05_01.tex
index 17db216e0f..ca15fa915f 100644
--- a/doc/05_01.tex
+++ b/doc/05_01.tex
@@ -20,7 +20,6 @@ Usage: scummvm [OPTIONS]... [GAME]\\
-e, --music-driver=MODE &Select music driver (see also section \ref{sect-music-and-sound})\\
-q, --language=LANG &Select language (see also section \ref{sect-languages})\\
-m, --music-volume=NUM &Set the music volume, 0-255 (default: 192)\\
- -o, --master-volume=NUM &Set the master volume, 0-255 (default: 192)\\
-s, --sfx-volume=NUM &Set the sfx volume, 0-255 (default: 192)\\
-r, --speech-volume=NUM &Set the voice volume, 0-255 (default: 192)\\
-n, --subtitles &Enable subtitles (use with games that have voice)\\
diff --git a/doc/08.tex b/doc/08.tex
index 756a6056fe..7c508ca600 100644
--- a/doc/08.tex
+++ b/doc/08.tex
@@ -41,7 +41,6 @@ An example config file looks as follows:
[tentacle]
path=C:\tentacle\
subtitles=true
- master_volume=98
music_volume=40
sfx_volume=255
@@ -90,7 +89,6 @@ The following keywords are recognized:
cdrom &number Number of CD-ROM unit to use for audio. If\\
& negative, don't even try to access the CD-ROM.\\
joystick\_num &number Number of joystick device to use for input\\
- master\_volume &number The master volume setting (0-255)\\
music\_driver &string The music engine to use.\\
output\_rate &number The output sample rate to use, in Hz. Sensible\\
& values are 11025, 22050 and 44100.\\
diff --git a/gui/launcher.cpp b/gui/launcher.cpp
index d3d8757424..5e9f9b3e08 100644
--- a/gui/launcher.cpp
+++ b/gui/launcher.cpp
@@ -252,8 +252,7 @@ void EditGameDialog::open() {
ConfMan.hasKey("native_mt32", _domain);
_globalAudioOverride->setState(e);
- e = ConfMan.hasKey("master_volume", _domain) ||
- ConfMan.hasKey("music_volume", _domain) ||
+ e = ConfMan.hasKey("music_volume", _domain) ||
ConfMan.hasKey("sfx_volume", _domain) ||
ConfMan.hasKey("speech_volume", _domain);
_globalVolumeOverride->setState(e);
diff --git a/gui/options.cpp b/gui/options.cpp
index 7bbbb98115..9bb21499d0 100644
--- a/gui/options.cpp
+++ b/gui/options.cpp
@@ -51,14 +51,13 @@ namespace GUI {
// - the save path (use _browser!)
// - music & graphics driver (but see also the comments on EditGameDialog
// for some techincal difficulties with this)
-// - default volumes (sfx/master/music)
+// - default volumes (sfx/speech/music)
// - aspect ratio, language, platform, subtitles, debug mode/level, cd drive, joystick, multi midi, native mt32
enum {
- kMasterVolumeChanged = 'mavc',
kMusicVolumeChanged = 'muvc',
kSfxVolumeChanged = 'sfvc',
- kSpeechVolumeChanged = 'vcvc',
+ kSpeechVolumeChanged = 'vcvc',
kChooseSaveDirCmd = 'chos',
kChooseExtraDirCmd = 'chex'
};
@@ -71,7 +70,6 @@ OptionsDialog::OptionsDialog(const String &domain, int x, int y, int w, int h)
_enableAudioSettings(false),
_multiMidiCheckbox(0), _mt32Checkbox(0), _subCheckbox(0),
_enableVolumeSettings(false),
- _masterVolumeSlider(0), _masterVolumeLabel(0),
_musicVolumeSlider(0), _musicVolumeLabel(0),
_sfxVolumeSlider(0), _sfxVolumeLabel(0),
_speechVolumeSlider(0), _speechVolumeLabel(0) {
@@ -134,13 +132,9 @@ void OptionsDialog::open() {
_subCheckbox->setState(ConfMan.getBool("subtitles", _domain));
}
- if (_masterVolumeSlider) {
+ if (_musicVolumeSlider) {
int vol;
- vol = ConfMan.getInt("master_volume", _domain);
- _masterVolumeSlider->setValue(vol);
- _masterVolumeLabel->setValue(vol);
-
vol = ConfMan.getInt("music_volume", _domain);
_musicVolumeSlider->setValue(vol);
_musicVolumeLabel->setValue(vol);
@@ -171,14 +165,12 @@ void OptionsDialog::close() {
}
}
- if (_masterVolumeSlider) {
+ if (_musicVolumeSlider) {
if (_enableVolumeSettings) {
- ConfMan.set("master_volume", _masterVolumeSlider->getValue(), _domain);
ConfMan.set("music_volume", _musicVolumeSlider->getValue(), _domain);
ConfMan.set("sfx_volume", _sfxVolumeSlider->getValue(), _domain);
ConfMan.set("speech_volume", _speechVolumeSlider->getValue(), _domain);
} else {
- ConfMan.removeKey("master_volume", _domain);
ConfMan.removeKey("music_volume", _domain);
ConfMan.removeKey("sfx_volume", _domain);
ConfMan.removeKey("speech_volume", _domain);
@@ -214,10 +206,6 @@ void OptionsDialog::close() {
void OptionsDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 data) {
switch (cmd) {
- case kMasterVolumeChanged:
- _masterVolumeLabel->setValue(_masterVolumeSlider->getValue());
- _masterVolumeLabel->draw();
- break;
case kMusicVolumeChanged:
_musicVolumeLabel->setValue(_musicVolumeSlider->getValue());
_musicVolumeLabel->draw();
@@ -261,8 +249,6 @@ void OptionsDialog::setAudioSettingsState(bool enabled) {
void OptionsDialog::setVolumeSettingsState(bool enabled) {
_enableVolumeSettings = enabled;
- _masterVolumeSlider->setEnabled(enabled);
- _masterVolumeLabel->setEnabled(enabled);
_musicVolumeSlider->setEnabled(enabled);
_musicVolumeLabel->setEnabled(enabled);
_sfxVolumeSlider->setEnabled(enabled);
@@ -340,12 +326,6 @@ int OptionsDialog::addMIDIControls(GuiObject *boss, int yoffset) {
int OptionsDialog::addVolumeControls(GuiObject *boss, int yoffset) {
// Volume controllers
- _masterVolumeSlider = new SliderWidget(boss, 5, yoffset, 185, 12, "Master volume: ", 100, kMasterVolumeChanged);
- _masterVolumeLabel = new StaticTextWidget(boss, 200, yoffset + 2, 24, kLineHeight, "100%", kTextAlignLeft);
- _masterVolumeSlider->setMinValue(0); _masterVolumeSlider->setMaxValue(255);
- _masterVolumeLabel->setFlags(WIDGET_CLEARBG);
- yoffset += 16;
-
_musicVolumeSlider = new SliderWidget(boss, 5, yoffset, 185, 12, "Music volume: ", 100, kMusicVolumeChanged);
_musicVolumeLabel = new StaticTextWidget(boss, 200, yoffset + 2, 24, kLineHeight, "100%", kTextAlignLeft);
_musicVolumeSlider->setMinValue(0); _musicVolumeSlider->setMaxValue(255);
diff --git a/gui/options.h b/gui/options.h
index 08965e7fe5..a1cd44a47c 100644
--- a/gui/options.h
+++ b/gui/options.h
@@ -82,9 +82,6 @@ private:
//
bool _enableVolumeSettings;
- SliderWidget *_masterVolumeSlider;
- StaticTextWidget *_masterVolumeLabel;
-
SliderWidget *_musicVolumeSlider;
StaticTextWidget *_musicVolumeLabel;
diff --git a/queen/queen.cpp b/queen/queen.cpp
index 2e1de0a0d2..22fad036f7 100644
--- a/queen/queen.cpp
+++ b/queen/queen.cpp
@@ -106,7 +106,6 @@ QueenEngine::~QueenEngine() {
}
void QueenEngine::registerDefaultSettings() {
- ConfMan.registerDefault("master_volume", 255);
ConfMan.registerDefault("music_mute", false);
ConfMan.registerDefault("sfx_mute", false);
ConfMan.registerDefault("talkspeed", Logic::DEFAULT_TALK_SPEED);
diff --git a/saga/music.cpp b/saga/music.cpp
index 79fb33f89b..338bf09977 100644
--- a/saga/music.cpp
+++ b/saga/music.cpp
@@ -518,7 +518,7 @@ int Music::play(uint32 music_rn, uint16 flags) {
parser->setTimerRate(_player->getBaseTempo());
_player->_parser = parser;
- _player->setVolume(ConfMan.getInt("music_volume") * ConfMan.getInt("master_volume") / 255);
+ _player->setVolume(ConfMan.getInt("music_volume"));
if (flags & MUSIC_LOOP)
_player->setLoop(true);
else
diff --git a/scumm/scumm.cpp b/scumm/scumm.cpp
index 57fb2ad54b..338b942429 100644
--- a/scumm/scumm.cpp
+++ b/scumm/scumm.cpp
@@ -1380,20 +1380,19 @@ void ScummEngine::setupMusic(int midi) {
void ScummEngine::setupVolumes() {
// Sync the engine with the config manager
- int soundVolumeMaster = ConfMan.getInt("master_volume");
int soundVolumeMusic = ConfMan.getInt("music_volume");
int soundVolumeSfx = ConfMan.getInt("sfx_volume");
int soundVolumeSpeech = ConfMan.getInt("speech_volume");
if (_musicEngine) {
- _musicEngine->setMusicVolume(soundVolumeMusic * soundVolumeMaster / 255);
+ _musicEngine->setMusicVolume(soundVolumeMusic);
}
- _mixer->setVolume(soundVolumeSfx * soundVolumeMaster / 255);
+ _mixer->setVolume(soundVolumeSfx);
_mixer->setMusicVolume(soundVolumeMusic);
if (_imuseDigital) {
- _mixer->setVolume(soundVolumeMaster);
+ _mixer->setVolume(255);
_imuseDigital->setGroupMusicVolume(soundVolumeMusic / 2);
_imuseDigital->setGroupSfxVolume(soundVolumeSfx / 2);
_imuseDigital->setGroupVoiceVolume(soundVolumeSpeech / 2);
diff --git a/scummvm.6 b/scummvm.6
index 099a42ca01..35a16d843c 100644
--- a/scummvm.6
+++ b/scummvm.6
@@ -103,10 +103,6 @@ Set the music volume to
range 0-255 (default: 192).
.It Fl n
Enable subtitles (use with games that have voice).
-.It Fl o Ar vol
-Set the master volume to
-.Ar vol
-range 0-255 (default: 192).
.It Fl p Ar path
Path to where the game is installed.
.It Fl q Ar language