From 874e340d25e79d067b7b5c2d72fe82c39da4a934 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 29 May 2009 17:38:22 +0000 Subject: Output a warning to the user, when he tries to play back MT32 MIDI tracks with a General MIDI device. svn-id: r41012 --- engines/kyra/sound_midi.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'engines/kyra/sound_midi.cpp') diff --git a/engines/kyra/sound_midi.cpp b/engines/kyra/sound_midi.cpp index 218b0d161d..f798251525 100644 --- a/engines/kyra/sound_midi.cpp +++ b/engines/kyra/sound_midi.cpp @@ -29,6 +29,8 @@ #include "common/system.h" #include "common/config-manager.h" +#include "gui/message.h" + namespace Kyra { class MidiOutput : public MidiDriver { @@ -467,6 +469,19 @@ SoundMidiPC::SoundMidiPC(KyraEngine_v1 *vm, Audio::Mixer *mixer, MidiDriver *dri // file extension. if (_vm->game() == GI_KYRA1 && _type == kMidiGM) _type = kMidiMT32; + + // Display a warning about possibly wrong sound when the user only has + // a General MIDI device, but the game is setup to use Roland MT32 MIDI. + // (This will only happen in The Legend of Kyrandia 1 though, all other + // supported games include special General MIDI tracks). + if (_type == kMidiMT32 && !_nativeMT32) { + ::GUI::MessageDialog dialog("You appear to be using a General MIDI device,\n" + "but your game only supports Roland MT32 MIDI.\n" + "We try to map the Roland MT32 instruments to\n" + "General MIDI ones. After all it might happen\n" + "that a few tracks will not be correctly played."); + dialog.runModal(); + } } SoundMidiPC::~SoundMidiPC() { -- cgit v1.2.3