diff options
Diffstat (limited to 'engines/sci/sound')
| -rw-r--r-- | engines/sci/sound/audio.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/audio.h | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/adlib.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/amigamac.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/cms.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/fb01.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/gm_names.h | 10 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/map-mt32-to-gm.h | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/midi.cpp | 7 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/mididriver.h | 3 | ||||
| -rw-r--r-- | engines/sci/sound/drivers/pcjr.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/midiparser_sci.cpp | 12 | ||||
| -rw-r--r-- | engines/sci/sound/midiparser_sci.h | 3 | ||||
| -rw-r--r-- | engines/sci/sound/music.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/music.h | 3 | ||||
| -rw-r--r-- | engines/sci/sound/soundcmd.cpp | 3 | ||||
| -rw-r--r-- | engines/sci/sound/soundcmd.h | 3 |
17 files changed, 20 insertions, 51 deletions
diff --git a/engines/sci/sound/audio.cpp b/engines/sci/sound/audio.cpp index 53311b4252..592caa5814 100644 --- a/engines/sci/sound/audio.cpp +++ b/engines/sci/sound/audio.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/resource.h" diff --git a/engines/sci/sound/audio.h b/engines/sci/sound/audio.h index 4cc8575a21..e0ba234b12 100644 --- a/engines/sci/sound/audio.h +++ b/engines/sci/sound/audio.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ /* Sound engine */ diff --git a/engines/sci/sound/drivers/adlib.cpp b/engines/sci/sound/drivers/adlib.cpp index f00c99d5b5..add3d8851f 100644 --- a/engines/sci/sound/drivers/adlib.cpp +++ b/engines/sci/sound/drivers/adlib.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/sci.h" diff --git a/engines/sci/sound/drivers/amigamac.cpp b/engines/sci/sound/drivers/amigamac.cpp index 7ee8d21f86..158b4b08fb 100644 --- a/engines/sci/sound/drivers/amigamac.cpp +++ b/engines/sci/sound/drivers/amigamac.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "audio/softsynth/emumidi.h" diff --git a/engines/sci/sound/drivers/cms.cpp b/engines/sci/sound/drivers/cms.cpp index 47c59a1e3d..ace96ba499 100644 --- a/engines/sci/sound/drivers/cms.cpp +++ b/engines/sci/sound/drivers/cms.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/sound/drivers/mididriver.h" diff --git a/engines/sci/sound/drivers/fb01.cpp b/engines/sci/sound/drivers/fb01.cpp index f217738bb2..9f3945bbec 100644 --- a/engines/sci/sound/drivers/fb01.cpp +++ b/engines/sci/sound/drivers/fb01.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/sci.h" diff --git a/engines/sci/sound/drivers/gm_names.h b/engines/sci/sound/drivers/gm_names.h index b7883494f6..bfe5ff88c7 100644 --- a/engines/sci/sound/drivers/gm_names.h +++ b/engines/sci/sound/drivers/gm_names.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_SOUND_DRIVERS_GM_NAMES_H @@ -28,6 +25,11 @@ namespace Sci { +// These tables are only used for debugging. Don't include them for devices +// with not enough available memory (e.g. phones), where REDUCE_MEMORY_USAGE +// is defined +#ifndef REDUCE_MEMORY_USAGE + static const char *GmInstrumentNames[] = { /*000*/ "Acoustic Grand Piano", /*001*/ "Bright Acoustic Piano", @@ -215,6 +217,8 @@ static const char *GmPercussionNames[] = { /*81*/ "Open Triangle" }; +#endif // REDUCE_MEMORY_USAGE + } // End of namespace Sci #endif // SCI_SOUND_DRIVERS_GM_NAMES_H diff --git a/engines/sci/sound/drivers/map-mt32-to-gm.h b/engines/sci/sound/drivers/map-mt32-to-gm.h index f7a6256ba4..12a36aa51c 100644 --- a/engines/sci/sound/drivers/map-mt32-to-gm.h +++ b/engines/sci/sound/drivers/map-mt32-to-gm.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_SOUND_DRIVERS_MAP_MT32_TO_GM_H diff --git a/engines/sci/sound/drivers/midi.cpp b/engines/sci/sound/drivers/midi.cpp index f36aac3a2a..93a2308410 100644 --- a/engines/sci/sound/drivers/midi.cpp +++ b/engines/sci/sound/drivers/midi.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/sci.h" @@ -819,11 +816,13 @@ void MidiPlayer_Midi::mapMt32ToGm(byte *data, size_t size) { if (_patchMap[i] == MIDI_UNMAPPED) { debugC(kDebugLevelSound, "[Unmapped]"); } else { +#ifndef REDUCE_MEMORY_USAGE if (_patchMap[i] >= 128) { debugC(kDebugLevelSound, "%s [Rhythm]", GmPercussionNames[_patchMap[i] - 128]); } else { debugC(kDebugLevelSound, "%s", GmInstrumentNames[_patchMap[i]]); } +#endif } _keyShift[i] = CLIP<uint8>(keyshift, 0, 48) - 24; @@ -855,10 +854,12 @@ void MidiPlayer_Midi::mapMt32ToGm(byte *data, size_t size) { } } +#ifndef REDUCE_MEMORY_USAGE if (_percussionMap[ins] == MIDI_UNMAPPED) debugC(kDebugLevelSound, "[Unmapped]"); else debugC(kDebugLevelSound, "%s", GmPercussionNames[_percussionMap[ins]]); +#endif _percussionVelocityScale[ins] = *(data + pos + 4 * i + 3) * 127 / 100; } diff --git a/engines/sci/sound/drivers/mididriver.h b/engines/sci/sound/drivers/mididriver.h index 2038725dbe..ec66984bd4 100644 --- a/engines/sci/sound/drivers/mididriver.h +++ b/engines/sci/sound/drivers/mididriver.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_SFX_SOFTSEQ_MIDIDRIVER_H diff --git a/engines/sci/sound/drivers/pcjr.cpp b/engines/sci/sound/drivers/pcjr.cpp index 4b1efb3c87..1d823b643d 100644 --- a/engines/sci/sound/drivers/pcjr.cpp +++ b/engines/sci/sound/drivers/pcjr.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/sound/drivers/mididriver.h" diff --git a/engines/sci/sound/midiparser_sci.cpp b/engines/sci/sound/midiparser_sci.cpp index 0b9d7617b8..95b165468d 100644 --- a/engines/sci/sound/midiparser_sci.cpp +++ b/engines/sci/sound/midiparser_sci.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "sci/engine/kernel.h" @@ -224,6 +221,7 @@ byte *MidiParser_SCI::midiFilterChannels(int channelMask) { byte command = 0, lastCommand = 0; int delta = 0; int midiParamCount = 0; + bool containsMidiData = false; _mixedData = outData; @@ -250,6 +248,9 @@ byte *MidiParser_SCI::midiFilterChannels(int channelMask) { } } if ((1 << curChannel) & channelMask) { + if (curChannel != 0xF) + containsMidiData = true; + if (command != kEndOfTrack) { // Write delta while (delta > 240) { @@ -307,6 +308,11 @@ byte *MidiParser_SCI::midiFilterChannels(int channelMask) { *outData++ = 0x00; *outData++ = 0x00; + // This occurs in the music tracks of LB1 Amiga, when using the MT-32 + // driver (bug #3297881) + if (!containsMidiData) + warning("MIDI parser: the requested SCI0 sound has no MIDI note data for the currently selected sound driver"); + return _mixedData; } diff --git a/engines/sci/sound/midiparser_sci.h b/engines/sci/sound/midiparser_sci.h index 39de425e18..82f34070a4 100644 --- a/engines/sci/sound/midiparser_sci.h +++ b/engines/sci/sound/midiparser_sci.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_MIDIPARSER_H diff --git a/engines/sci/sound/music.cpp b/engines/sci/sound/music.cpp index c7743ac587..96cbf135ed 100644 --- a/engines/sci/sound/music.cpp +++ b/engines/sci/sound/music.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "audio/audiostream.h" diff --git a/engines/sci/sound/music.h b/engines/sci/sound/music.h index dfe5ad1586..8577ed7313 100644 --- a/engines/sci/sound/music.h +++ b/engines/sci/sound/music.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_MUSIC_H diff --git a/engines/sci/sound/soundcmd.cpp b/engines/sci/sound/soundcmd.cpp index a2b09eab4c..4ea290ff9e 100644 --- a/engines/sci/sound/soundcmd.cpp +++ b/engines/sci/sound/soundcmd.cpp @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #include "common/config-manager.h" diff --git a/engines/sci/sound/soundcmd.h b/engines/sci/sound/soundcmd.h index cae72e2cdb..a542a8b384 100644 --- a/engines/sci/sound/soundcmd.h +++ b/engines/sci/sound/soundcmd.h @@ -18,9 +18,6 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * $URL$ - * $Id$ - * */ #ifndef SCI_SOUNDCMD_H |
