We’re trying to play some MIDI files using a custom .dls soundbank, and have faced numerous issues. For some background information, we’re testing and getting consistent results on both YoYo Games’ FMOD Studio Core extension for GameMaker, and an unofficial FMODex-based extension for GameMaker Studio 1.4.
Only .dls level 1 and level 1/2 files are accepted. Using a tool called Extreme Sample Converter 3 (the only free tool we could find that would let us edit .dls files), we’ve been able to convert .sf2 soundfonts to .dls level 2, and hex-editing the file to change instances of “rgn2” to "rgn " makes them audible in FMOD.
When they are audible in FMOD, they completely ignore any volume envelopes attached to instruments. The soundbank we’re looking to use relies heavily on volume envelopes. It does recognize the volume envelopes present in the gm.dls soundbank included with Windows, so I would appreciate guidance on what exactly needs to be present in this file in order to make it work with FMOD. We’ve only been able to edit the file using the aforementioned Extreme Sample Converter 3, which, as I said, only directly exports .dls level 2, which doesn’t seem to be compatible with FMOD.
Version 2.02.20, as YoYo Games’ GMEXT-FMOD extension requires.
As for .dls level 1, I ended up finding an old version of Microsoft DirectMusic Producer, and used that to create a (fully compatible, according to the program’s checker tool) level 1 .dls version of the one I’m trying to use, using what that program called “DLS1 Articulation”. It was just some basic attack, delay, and sustain. This version of the .dls was completely silent. When I used ESC3 to convert it to .dls 2, and then hex-edit it back to .dls 1, it had sound, but without the articulations.
MM10NEW.dls is the level 1 file created with MS DirectMusic Producer - this file does not play sound
MM10NEW_DLS2CONV.dls is the previous file converted to level 2 with ESC3 - this file does not play sound
MM10NEW_DLS2CONV_EDIT.dls is the previous file with all instances of “rgn2” hex-edited to be "rgn " - this file does play sound, but without the articulations
Thank you very much for your response. I hope there’s nothing I’m missing, I believe I’ve covered everything I have.
Thank you for providing the information and the .dsl files, the midi files were not included, could I get those too? Would it be possible to also get a code snippet of how you play the sounds?
Thank you for sharing those files. While I continue to investigate the issue. Can you please confirm if you experience the same issue using our example API included in the engine download? The examples can be found here on Windows: "C:\Program Files (x86)\FMOD SoundSystem\FMOD Studio API Windows\api\studio\examples\vs2019\examples.sln"
Thank you for providing your MIDI and DLS files for analysis. I’ve taken a look at MM10NEW.dls, the reason you cannot hear anything is because of the bank selection. Your MIDI files are looking for instruments in bank 0, however MM10NEW.dls has all its instruments within bank 1. I was able to get your MIDI to play by hacking our source but you should be able to get it working by either switching your MIDI to use bank 1 or tweaking the DLS to export all instruments as bank 0.