From fcdb349fa2bf4d93254ca38037483010e6a6c819 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Wed, 25 Aug 2010 07:41:14 +0000 Subject: AGI: Respect mute setting svn-id: r52373 --- engines/agi/agi.cpp | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'engines/agi/agi.cpp') diff --git a/engines/agi/agi.cpp b/engines/agi/agi.cpp index e83ef4ead9..b15a4c3bac 100644 --- a/engines/agi/agi.cpp +++ b/engines/agi/agi.cpp @@ -501,8 +501,7 @@ AgiBase::AgiBase(OSystem *syst, const AGIGameDescription *gameDesc) : Engine(sys AgiEngine::AgiEngine(OSystem *syst, const AGIGameDescription *gameDesc) : AgiBase(syst, gameDesc) { // Setup mixer - _mixer->setVolumeForSoundType(Audio::Mixer::kSFXSoundType, ConfMan.getInt("sfx_volume")); - _mixer->setVolumeForSoundType(Audio::Mixer::kMusicSoundType, ConfMan.getInt("music_volume")); + syncSoundSettings(); parseFeatures(); @@ -709,18 +708,6 @@ Common::Error AgiEngine::go() { return Common::kNoError; } -void AgiEngine::syncSoundSettings() { - // FIXME/TODO: Please explain why we are using "music_volume" for all - // three different entries here. - int soundVolumeMusic = ConfMan.getInt("music_volume"); - int soundVolumeSFX = ConfMan.getInt("music_volume"); - int soundVolumeSpeech = ConfMan.getInt("music_volume"); - - _mixer->setVolumeForSoundType(Audio::Mixer::kMusicSoundType, soundVolumeMusic); - _mixer->setVolumeForSoundType(Audio::Mixer::kSFXSoundType, soundVolumeSFX); - _mixer->setVolumeForSoundType(Audio::Mixer::kSpeechSoundType, soundVolumeSpeech); -} - void AgiEngine::parseFeatures() { if (!ConfMan.hasKey("features")) return; -- cgit v1.2.3 From 763c089d06dbe3c14789eff13c98b87380c46a6a Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 20 Sep 2010 21:17:49 +0000 Subject: AGI: Fix bug #3061578: AGI: PCjr Mode Not Default for DOS Games svn-id: r52831 --- engines/agi/agi.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'engines/agi/agi.cpp') diff --git a/engines/agi/agi.cpp b/engines/agi/agi.cpp index b15a4c3bac..559e2243bd 100644 --- a/engines/agi/agi.cpp +++ b/engines/agi/agi.cpp @@ -578,15 +578,15 @@ void AgiEngine::initialize() { } else if (getPlatform() == Common::kPlatformCoCo3) { _soundemu = SOUND_EMU_COCO3; } else { - switch (MidiDriver::getMusicType(MidiDriver::detectDevice(MDT_PCSPK|MDT_ADLIB|MDT_PCJR|MDT_MIDI))) { + switch (MidiDriver::getMusicType(MidiDriver::detectDevice(MDT_PCSPK|MDT_AMIGA|MDT_PCJR|MDT_MIDI))) { case MT_PCSPK: _soundemu = SOUND_EMU_PC; break; case MT_PCJR: _soundemu = SOUND_EMU_PCJR; break; - case MT_ADLIB: - _soundemu = SOUND_EMU_NONE; + case MT_AMIGA: + _soundemu = SOUND_EMU_AMIGA; break; default: _soundemu = SOUND_EMU_MIDI; -- cgit v1.2.3 From d43ff54a0894c30ea19b10541fd5a7f077892cc9 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Tue, 21 Sep 2010 05:36:51 +0000 Subject: AGI: Changed meaning of pcjr sound device. Now it is Sarien emu Music drivers: default: proper Tandy/PCJr adlib: proper Tandy/PCJr pcjr: old Sarien emu amiga: old Sarien emu in Amiga mode pcspk: Sarien emu in PCSpk mode (quite wrong) midi: 4 channel MIDI svn-id: r52836 --- engines/agi/agi.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'engines/agi/agi.cpp') diff --git a/engines/agi/agi.cpp b/engines/agi/agi.cpp index 559e2243bd..508f473609 100644 --- a/engines/agi/agi.cpp +++ b/engines/agi/agi.cpp @@ -578,17 +578,23 @@ void AgiEngine::initialize() { } else if (getPlatform() == Common::kPlatformCoCo3) { _soundemu = SOUND_EMU_COCO3; } else { - switch (MidiDriver::getMusicType(MidiDriver::detectDevice(MDT_PCSPK|MDT_AMIGA|MDT_PCJR|MDT_MIDI))) { + switch (MidiDriver::getMusicType(MidiDriver::detectDevice(MDT_PCSPK|MDT_AMIGA|MDT_ADLIB|MDT_PCJR|MDT_MIDI))) { case MT_PCSPK: _soundemu = SOUND_EMU_PC; break; - case MT_PCJR: + case MT_ADLIB: + // Default sound is the proper PCJr emulation _soundemu = SOUND_EMU_PCJR; break; + case MT_PCJR: + // Under PCJr Sarien emu is disguised + _soundemu = SOUND_EMU_NONE; + break; case MT_AMIGA: _soundemu = SOUND_EMU_AMIGA; break; default: + debug(0, "DEF"); _soundemu = SOUND_EMU_MIDI; break; } -- cgit v1.2.3 From f994deb4eeda51eb3a73e555b69f44e8ee1a6c6a Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Tue, 21 Sep 2010 06:05:27 +0000 Subject: AGI: Deconfusify the AGI music driver (After a brief discussion with sev.) AdLib is now the old Sarien sound, PCjr is the new PCjr emulation. PCjr is still the default; we don't need to ask getMusicType() how to get there. svn-id: r52838 --- engines/agi/agi.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'engines/agi/agi.cpp') diff --git a/engines/agi/agi.cpp b/engines/agi/agi.cpp index 508f473609..0646f321d4 100644 --- a/engines/agi/agi.cpp +++ b/engines/agi/agi.cpp @@ -577,18 +577,19 @@ void AgiEngine::initialize() { _soundemu = SOUND_EMU_APPLE2GS; } else if (getPlatform() == Common::kPlatformCoCo3) { _soundemu = SOUND_EMU_COCO3; + } else if (ConfMan.get("music_driver") == "auto") { + // Default sound is the proper PCJr emulation + _soundemu = SOUND_EMU_PCJR; } else { switch (MidiDriver::getMusicType(MidiDriver::detectDevice(MDT_PCSPK|MDT_AMIGA|MDT_ADLIB|MDT_PCJR|MDT_MIDI))) { case MT_PCSPK: _soundemu = SOUND_EMU_PC; break; case MT_ADLIB: - // Default sound is the proper PCJr emulation - _soundemu = SOUND_EMU_PCJR; + _soundemu = SOUND_EMU_NONE; break; case MT_PCJR: - // Under PCJr Sarien emu is disguised - _soundemu = SOUND_EMU_NONE; + _soundemu = SOUND_EMU_PCJR; break; case MT_AMIGA: _soundemu = SOUND_EMU_AMIGA; -- cgit v1.2.3