Skip to content
This repository has been archived by the owner on Jun 23, 2023. It is now read-only.

[Suggestion] Disable chorus and reverb for Fluidsynth by default #65

Closed
sinisterseed opened this issue Feb 28, 2020 · 1 comment
Closed
Labels

Comments

@sinisterseed
Copy link

sinisterseed commented Feb 28, 2020

Chorus and reverb usually make the music sound awful when played back through Fluidsynth in PrBoom, and the worst part is that there are no menu entries to turn them off, they have to be manually turned off in the config once found.

The majority of MIDIs are not designed with these in mind, so there's no real good reason to keep them ON by default.

@fabiangreffrath
Copy link
Collaborator

fabiangreffrath commented Apr 16, 2020

This disables chorus and reverb by default and mitigates their impact for those with an existing config based on the suggestions by @kitchen-ace found in chocolate-doom/chocolate-doom#1261

diff --git a/prboom2/src/MUSIC/flplayer.c b/prboom2/src/MUSIC/flplayer.c
index 2d5eff1e..09c5fd49 100644
--- a/prboom2/src/MUSIC/flplayer.c
+++ b/prboom2/src/MUSIC/flplayer.c
@@ -144,6 +144,20 @@ static int fl_init (int samplerate)
   FSET (int, "synth.chorus.active", mus_fluidsynth_chorus);
   FSET (int, "synth.reverb.active", mus_fluidsynth_reverb);

+  if (mus_fluidsynth_chorus)
+  {
+    FSET (num, "synth.chorus.depth", (double) 5);
+    FSET (num, "synth.chorus.level", (double) 0.35);
+  }
+
+  if (mus_fluidsynth_reverb)
+  {
+    FSET (num, "synth.reverb.damp", (double) 0.4);
+    FSET (num, "synth.reverb.level", (double) 0.15);
+    FSET (num, "synth.reverb.width", (double) 4);
+    FSET (num, "synth.reverb.room-size", (double) 0.6);
+  }
+
   // gain control
   FSET (num, "synth.gain", mus_fluidsynth_gain / 100.0); // 0.0 - 0.2 - 10.0
   // behavior wrt bank select messages
diff --git a/prboom2/src/m_misc.c b/prboom2/src/m_misc.c
index ec04c31b..8f4daa43 100644
--- a/prboom2/src/m_misc.c
+++ b/prboom2/src/m_misc.c
@@ -381,8 +381,8 @@ default_t defaults[] =
   {"mus_extend_volume",{&mus_extend_volume},{0},0,1,
    def_bool,ss_none}, // e6y: apply midi volume to all midi devices
 #endif
-  {"mus_fluidsynth_chorus",{&mus_fluidsynth_chorus},{1},0,1,def_bool,ss_none},
-  {"mus_fluidsynth_reverb",{&mus_fluidsynth_reverb},{1},0,1,def_bool,ss_none},
+  {"mus_fluidsynth_chorus",{&mus_fluidsynth_chorus},{0},0,1,def_bool,ss_none},
+  {"mus_fluidsynth_reverb",{&mus_fluidsynth_reverb},{0},0,1,def_bool,ss_none},
   {"mus_fluidsynth_gain",{&mus_fluidsynth_gain},{50},0,1000,def_int,ss_none}, // NSM  fine tune fluidsynth output level
   {"mus_opl_gain",{&mus_opl_gain},{50},0,1000,def_int,ss_none}, // NSM  fine tune opl output level


Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants