audio plugin host appears to invoke initialise twice. use singleton fluidsynth model now to survive that. also, clear midi output to make VST3 stop complaining

This commit is contained in:
Alex Birch
2018-02-27 23:33:19 +00:00
parent c129ce78a0
commit f89da1834c
2 changed files with 8 additions and 0 deletions

View File

@ -20,6 +20,10 @@ FluidSynthModel::~FluidSynthModel() {
}
void FluidSynthModel::initialise() {
if (initialised) {
delete_fluid_synth(synth);
delete_fluid_settings(settings);
}
settings = new_fluid_settings();
// https://sourceforge.net/p/fluidsynth/wiki/FluidSettings/
fluid_settings_setstr(settings, "synth.verbose", "yes");