Skip to content

Commit

Permalink
move one line of code to fix CoreAudio deadlock on macOS FL Studio
Browse files Browse the repository at this point in the history
  • Loading branch information
Birch-san committed Aug 1, 2019
1 parent 5989267 commit 90fcae8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Source/FluidSynthModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@ FluidSynthModel::~FluidSynthModel() {
}

void FluidSynthModel::initialise() {
settings = { new_fluid_settings(), delete_fluid_settings };

// deactivate all audio drivers in fluidsynth to avoid FL Studio deadlock when initialising CoreAudio
// after all: we only use fluidsynth to render blocks of audio. it doesn't output to audio driver.
const char *DRV[] {NULL};
fluid_audio_driver_register(DRV);

settings = { new_fluid_settings(), delete_fluid_settings };

// https://sourceforge.net/p/fluidsynth/wiki/FluidSettings/
#if JUCE_DEBUG
fluid_settings_setint(settings.get(), "synth.verbose", 1);
Expand Down

0 comments on commit 90fcae8

Please sign in to comment.