Soundfonts can be very useful in some cases but seem to have some limitations. Surprisingly there seems to be no method exposed in AudioKit that allows to just change the preset of an already loaded soundfont which would of course be the most common scenario. In my case there is only one soundfont ever used, but instead of being able to switch presets on it, which is the main reason to have a soundfont in the first place, I have to use one of the 3 load soundfont methods like loadMelodicSoundFont and each time reload the entire file. That seems inefficient as these files tend to be rather large. Is there another way to change the preset?
Currently changing soundfont presets like this:
do {
try loadMelodicSoundFont(soundFontTitle, preset: gmPreset)
} catch { print("load soundfont failed with error: \(error)") }