[Scummvm-cvs-logs] CVS: scummvm/sound mididrv.cpp,1.55,1.56 module.mk,1.17,1.18

Max Horn fingolfin at users.sourceforge.net
Sat Dec 25 10:35:03 CET 2004


Update of /cvsroot/scummvm/scummvm/sound
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14193/sound

Modified Files:
	mididrv.cpp module.mk 
Log Message:
Moved the softsynth midi drivers into a sound/softsynth; amongst other things, this fixes bug #1083058

Index: mididrv.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sound/mididrv.cpp,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- mididrv.cpp	14 Dec 2004 01:02:55 -0000	1.55
+++ mididrv.cpp	25 Dec 2004 18:34:44 -0000	1.56
@@ -137,3 +137,54 @@
 
 	return musicDriver;
 }
+
+MidiDriver *MidiDriver::createMidi(int midiDriver) {
+	switch(midiDriver) {
+	case MD_NULL:      return MidiDriver_NULL_create();
+
+	// In the case of Adlib, we won't specify anything.
+	// IMuse is designed to set up its own Adlib driver
+	// if need be, and we only have to specify a native
+	// driver.
+	case MD_ADLIB:     return NULL;
+
+#ifdef USE_MT32EMU
+	case MD_MT32:      return MidiDriver_MT32_create(g_engine->_mixer);
+#endif
+
+	case MD_TOWNS:     return MidiDriver_YM2612_create(g_engine->_mixer);
+
+	// Right now PC Speaker and PCjr are handled
+	// outside the MidiDriver architecture, so
+	// don't create anything for now.
+	case MD_PCSPK:
+	case MD_PCJR:      return NULL;
+#if defined(__PALM_OS__)
+	case MD_YPA1:      return MidiDriver_YamahaPa1_create();
+#ifndef DISABLE_TAPWAVE
+	case MD_ZODIAC:    return MidiDriver_Zodiac_create();
+#endif
+#endif
+#if defined(WIN32) && !defined(_WIN32_WCE)
+	case MD_WINDOWS:   return MidiDriver_WIN_create();
+#endif
+#if defined(__MORPHOS__)
+	case MD_ETUDE:     return MidiDriver_ETUDE_create();
+#endif
+#if defined(UNIX) && !defined(__BEOS__) && !defined(MACOSX)
+	case MD_SEQ:       return MidiDriver_SEQ_create();
+#endif
+#if (defined(MACOSX) || defined(macintosh)) && !defined(__PALM_OS__)
+	case MD_QTMUSIC:   return MidiDriver_QT_create();
+#endif
+#if defined(MACOSX)
+	case MD_COREAUDIO: return MidiDriver_CORE_create();
+#endif
+#if defined(UNIX) && defined(USE_ALSA)
+	case MD_ALSA:      return MidiDriver_ALSA_create();
+#endif
+	}
+
+	error("Invalid midi driver selected");
+	return NULL;
+}

Index: module.mk
===================================================================
RCS file: /cvsroot/scummvm/scummvm/sound/module.mk,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- module.mk	22 Feb 2004 14:11:10 -0000	1.17
+++ module.mk	25 Dec 2004 18:34:44 -0000	1.18
@@ -14,11 +14,14 @@
 	sound/rate.o \
 	sound/voc.o \
 	sound/vorbis.o \
-	sound/flac.o
-#	sound/resample.o \
+	sound/flac.o \
+	sound/softsynth/adlib.o \
+	sound/softsynth/ym2612.o \
+	sound/softsynth/mt32.o \
 
 MODULE_DIRS += \
-	sound
+	sound \
+	sound/softsynth
 
 # Include common rules 
 include $(srcdir)/common.rules





More information about the Scummvm-git-logs mailing list