Partial fix for Bug [636985] ZAK256: No kazoo tune

Implemented a parser for Euphony music. No
FM instrument support yet, as the FM chip used
by FM Towns is not being emulated yet. In the
meantime, a stock FM-emulated GM instrument is
being used instead.

This at least makes the Zak Towns kazoo tune
and the Loom Towns distaff audible. Emulation
of the FM Towns synth chip, or suitable
emulation using the OPL2 synth, is still
under investigation.

svn-id: r10265
This commit is contained in:
Jamieson Christian 2003-09-16 11:44:48 +00:00
parent 00c1fdce3a
commit 091b41a278
8 changed files with 221 additions and 22 deletions

View file

@ -39,6 +39,7 @@
////////////////////////////////////////
extern MidiParser *MidiParser_createRO();
extern MidiParser *MidiParser_createEUP();
static uint read_word(byte *a) {
return (a[0] << 8) + a[1];
@ -186,6 +187,9 @@ int Player::start_seq_sound(int sound, bool reset_vars) {
if (!memcmp (ptr, "RO", 2)) {
// Old style 'RO' resource
_parser = MidiParser_createRO();
} else if (!memcmp (ptr, "SO", 2)) {
// Euphony (FM Towns) resource
_parser = MidiParser_createEUP();
} else if (!memcmp(ptr, "FORM", 4)) {
// Humongous Games XMIDI resource
_parser = MidiParser::createParser_XMIDI();