billthefarmer/mididriver

Support for .sf2 Files

rodydavis opened this issue · 7 comments

Would .sf2 files ever be a possibility?

AFAIK, nobody has been able to get the code for loading DLS files to work - #21. DLS files are very similar to SF2 files, they use the same Amiga RIFF format, so they could be converted.

Gotcha, is there a better format to use?

If some clever soul out there can work out how to use the code in the Sonivox synthesizer for loading DLS files that would be possible. I think Google know how it works because they have fixed bugs in it.

I was able to do this in my own Android MIDI Library with .SF2 files for future reference.

https://github.com/AppleEducate/MidiDriver-Android-SF2

I use this in a Flutter Plugin but this will work for all android projects.

I was able to do this in my own Android MIDI Library with .SF2 files for future reference.

https://github.com/AppleEducate/MidiDriver-Android-SF2

I use this in a Flutter Plugin but this will work for all android projects.

@rodydavis Unfortunately this is a fork of KyoSherlock/MidiDriver, which has been improperly licensed: github.com/KyoSherlock/MidiDriver/issues/8

I'm not sure the best way to fix this. Would the upstream project need to be relicensed first? If it's unable to be fixed then it might be good to add a warning to your project as it shouldn't really be used until then.

(as I commented below, this is wrong)

Yeah good point, the license is needed

Yeah good point, the license is needed

I was wrong! 😅 It looks like that issue incorrectly stated that GPLv2 code was included in an Apache 2-licensed project, but it turns out the included code is actually GPLv2 with the classpath exception. So your project is fine. I think I'll probably try it out myself since this project isn't able to load sound fonts at the moment.

My biggest concern is that doing all this in Java instead of natively will be slow (e.g. KyoSherlock/MidiDriver#5) but I guess I'll find out soon enough...