Skip to content

Commit

Permalink
Fix for #27
Browse files Browse the repository at this point in the history
using "audio.jack.autoconnect" when the audio driver is "jack"
  • Loading branch information
pedrolcl committed Aug 30, 2024
1 parent c7f8e80 commit 1434ae5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion library/rt-backends/fluidsynth/fluidsynthengine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ const QString FluidSynthEngine::QSTR_DATADIR = QStringLiteral("soundfonts");
const QString FluidSynthEngine::QSTR_DATADIR2 = QStringLiteral("sounds/sf2");
const QString FluidSynthEngine::QSTR_SOUNDFONT = QStringLiteral("default.sf2");
const QString FluidSynthEngine::QSTR_PULSEAUDIO = QStringLiteral("pulseaudio");
const QString FluidSynthEngine::QSTR_JACK = QStringLiteral("jack");

const QString FluidSynthEngine::QSTR_AUDIODRIVER = QStringLiteral("AudioDriver");
const QString FluidSynthEngine::QSTR_BUFFERTIME = QStringLiteral("BufferTime");
Expand Down Expand Up @@ -131,7 +132,9 @@ void FluidSynthEngine::initializeSynth()
::fluid_settings_setint(m_settings, "audio.periods", fs_periods);
if (fs_audiodriver == QSTR_PULSEAUDIO) {
::fluid_settings_setint(m_settings, "audio.pulseaudio.adjust-latency", 0);
}
} else if (fs_audiodriver == QSTR_JACK) {
::fluid_settings_setint(m_settings, "audio.jack.autoconnect", 1);
}

::fluid_settings_setnum(m_settings, "synth.reverb.damp", fs_reverb_damp);
::fluid_settings_setnum(m_settings, "synth.reverb.level", fs_reverb_level);
Expand Down
1 change: 1 addition & 0 deletions library/rt-backends/fluidsynth/fluidsynthengine.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ class FluidSynthEngine : public QObject
static const QString QSTR_DEFAULT_AUDIODRIVER;
static const QString QSTR_BUFFERTIME;
static const QString QSTR_PULSEAUDIO;
static const QString QSTR_JACK;

static const QString QSTR_CHORUS_DEPTH;
static const QString QSTR_CHORUS_LEVEL;
Expand Down

0 comments on commit 1434ae5

Please sign in to comment.