[Scummvm-cvs-logs] scummvm master -> b5c584ff748e0ea85148d01f3a689b8ba00684ce

eriktorbjorn eriktorbjorn at telia.com
Sat May 30 19:24:36 CEST 2015


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
b5c584ff74 FMOPL: Fix confusing "opl_driver" behavior


Commit: b5c584ff748e0ea85148d01f3a689b8ba00684ce
    https://github.com/scummvm/scummvm/commit/b5c584ff748e0ea85148d01f3a689b8ba00684ce
Author: Torbjörn Andersson (eriktorbjorn at users.sourceforge.net)
Date: 2015-05-30T19:18:29+02:00

Commit Message:
FMOPL: Fix confusing "opl_driver" behavior

The way I've configured ScummVM, the default is to use FluidSynth
for MIDI, and any game where I want AdLib overrides that setting.
I have set the DOSBox OPL emulator as the default.

However, this causes the game's "opl_driver" setting to be "auto",
which overrides the default setting, and usually picks the MAME
OPL emulator. To counter this, if it sees that "opl_driver" is
"auto", it will check the default setting.

In other words, only use "auto" if "opl_driver" isn't set on any
level. I think this is the behaviour that should cause the least
amount of astonishment.

Changed paths:
    audio/fmopl.cpp



diff --git a/audio/fmopl.cpp b/audio/fmopl.cpp
index c18e544..30229ea 100644
--- a/audio/fmopl.cpp
+++ b/audio/fmopl.cpp
@@ -80,6 +80,12 @@ Config::DriverId Config::detect(OplType type) {
 	}
 
 	DriverId drv = parse(ConfMan.get("opl_driver"));
+	if (drv == kAuto) {
+		// Since the "auto" can be explicitly set for a game, and this
+		// driver shows up in the GUI as "<default>", check if there is
+		// a global setting for it before resorting to auto-detection.
+		drv = parse(ConfMan.get("opl_driver", Common::ConfigManager::kApplicationDomain));
+	}
 
 	// When a valid driver is selected, check whether it supports
 	// the requested OPL chip.






More information about the Scummvm-git-logs mailing list