As a safety check...
Also throw out some warnings when loading savegames
with instrument data for a different device (the savegame
incompatibility would be very nice to be fixed, but it is not
trivial.
Currently, Roland MT-32 sound is broken for
SAMNMAX. Just try the intro song with shut off
speech. It is very obvious that it plays with a quite
reduced number of channels compared to the
original interpreter.
Now, due to the not-so-helpful code design (much
of the iMuse code has been drawn into the common
code) it has become increasingly difficult to fix Midi
related thing in iMuse. I have added more and more
crude hacks over time.
SAMNMAX requires more elaborate channel
allocation. To make it happen I have added driver
wrappers for Midi to the iMuse code.
Other than that, I have done only minor cleanup here.
Actually, I would have liked to withdraw much more
of the iMuse code from the common code and move
it to SCUMM (basically all the MidiChannel
stuff which is exclusively used by iMuse. But it turns
out that it is so thoroughly intertwined (the major
blocker here being the AdLib driver) that it requires
more thought and effort and would just distract me
from fixing the SAMNMAX sound.
This will actually read out of bounds in the orginal interpreter, too. I have fixed it to be more in line with the original (the value in question is always treated as unsigned here), but still not do anything harmful.
This was previously disabled implicitly by the missing define
symbols in the SampleRateConvertor module. This has now been enabled
to use the internal rate convertor code.
This was generating undefined macro warnings from GCC when -Wundef
was passed.
Reduce abuse of the property function to set init vars.
Better distinction between drivers to prevent a GM init on
the Mac driver (which could happen depending on the
launcher sound setting).
Continued bug fixing for ticket no. 13460 ("Incorrect MIDI
pitch bending"). This time the AdLib part (which applies
to FM-Towns, too, since it is more or less the same driver).
This fixes the sound when the bird is dropping from the
sky in the DOTT intro.
Also separate the GM code for SAMNMAX a bit after
checking the original code.
This fixes a possible infinite loop in VocStream. It depends on the stream size
matching the size specified in the VOC block headers, but if the size in the
headers is incorrect and larger than the stream size, it will keep trying to
read the stream. This is fixed by adding an end-of-stream check to the error
check.
To implement a MOD variant for the Chewy engine, this commit makes some changes
to make subclassing of the ProtrackerStream and associated Module class easier.
Backyard Baseball 2003 was missing dialog which was lip-synced to
animation. This was due to it using the WAV block alignment as a count
of bytes per sample. This is not true for the IMA ADPCM format used for
speech in Backyard Baseball 2003.
This commit adds a mediator class to decouple the CMS emulator from the engines
that use it. This allows for easier updating or replacement of the emulator or
addition of new emulators. It also enables using the emulator via a callback
mechanism.
This adds a MIDI driver for the Casio MT-540, CT-460 and CSM-1 devices. These
are supported by Elvira 1 and several Sierra SCI0 games as well as Altered
Destiny and Les Manley 1.
This commit adds the following functionality to the MIDI drivers:
- Add checking if a driver is ready to process MIDI events for a specific
source (rather than any source). To facilitate this, SysExes can now be sent
using a source number. This is stored with the SysEx data in the SysEx queue
and can be checked when isReady is called with a source number.
- Allow specifying controller default values per MIDI channel. Currently this
is only implemented for program.
- The OPL dynamic channel allocation algorithm will now respect statically
allocated channels, in case a subclass uses combined static and dynamic channel
allocation.
It also fixes the following bugs:
- Instrument remapping can now be specified using const arrays.
- OPL instrument writing code is refactored to a separate function.
- OPL note on with velocity 0 would be handled as a note off, and then
continued to be processed as a note on.
- OPL writeFrequency would always write key on bit, even if the note is not
active.
- MT-32 default channel volume was incorrect.
The auto loop functionality of the MIDI parser would call jumpToTick to jump
back to the start of the MIDI stream, then call parseNextEvent to read the
first MIDI event. However, jumpToTick already makes sure the first MIDI event
after the jump point is parsed. Calling parseNextEvent again would discard the
first and parse the second MIDI event.
Fixed this by removing the call to parseNextEvent after jumping to the start.
This commit adds a function to the multisource MIDI drivers for specifying an
arbitrary instrument map for remapping the instruments in the MIDI data.
This is used for remapping instruments from two Simon 2 GM tracks to MT-32
because they are missing from the MT-32 MIDI data set.
This commit adds MIDI parser subclasses for the Simon 1 GMF format and for the
SMF variant used by the Windows versions of Simon 1 and 2.
The GMF format was handled by the SMF parser, which can now be removed from
that class. It also fixes the tempos not matching the DOS interpreter.
The Simon Windows SMF variant was handled in the AGOS midi class. Moving it to
a separate parser allows for some cleaner code in that class. It now also
corrects the tempos to match those of the DOS interpreter.
This adds support for the OPL rhythm mode to the AdLib multisource MIDI driver.
Some games (f.e. Simon 1) use this to generate the rhythm sounds of their music.
This was previously disabled implicitly by the missing define
symbols in the SampleRateConvertor module. This has now been enabled
to use the internal rate convertor code.
This was generating undefined macro warnings from GCC when -Wundef
was passed.
This commit adds support for the SudoMaker RetroWave OPL3 sound card. Requires
the retrowave library.
Add the following settings to scummvm.ini:
retrowaveopl3_bus=serial
retrowaveopl3_port=<port> f.e. COM3 or ttyACM0