Sunday, November 1, 2015

Simple Graphical Interface for FluidSynth

I had a Korg Triton synthesizer for a long time, and was thinking of getting a new synth for fun.  Though I noticed really everything for a synthesizer can be done in open source software now.  For example, you can download free .sf2 soundfont files (some of which sound more realistic than my Korg).  On Linux, you can use jack and fluidsynth to do the midi synthesis.  You can even do sequencing in Rosegarden, or standard multitrack recording in Ardour or Audacity.

The only physical piece of hardware you need is a usb midi device.  So for maybe under $100, you can get what would easily be a $1000 synth (if you were buying a traditional hardware synth).  :-)

The only downside, fluidsynth is by default a command line program.

There are some graphical front end programs for it, but I found them to be difficult to use for what I needed.  I typically use a synth for multitrack overdubs, or just playing around on, less for midi sequencing.  So, I wanted an interface that looked similar to a classic synth.  For example: I wanted to to see all the soundfont files as "voices" and then easily cycle through the instruments in each soundfont -- with one key press.   Or, to search through the soundfont files, for example, to see all "organ" voices at a glance.

So... I gave up on finding a simple graphical interface that worked for me, and I just spent a few days writing exactly what I wanted.  Also, it was a nice excuse to poke around Python.  I don't use it very often.   Also I thought it would be easier for others to take apart or extend.

The source code (single file) is at git hub:

The graphical interface looks like this:

The default tab:

The second tab (some level controls):


  • Put all your sound fonts in a folder, and select the folder.   Then, if you press the Up/Down arrows (on the sound font list) you'll quickly cycle through the voices.  If you press the Left/Right arrows, you'll quickly cycle through the available instruments contained in the soundfont. 
  • There's also a search filter at bottom.  (You can also search while the sountfont list has the focus, and this adds a search filter at bottom.)  For example, if you type "moog," the list will be filtered to only items that contain "moog" in the name.  When searching, SPACE is a wildcard.  ESC clears the search box.
  • If you organize the fonts in a folder, you can also search and navigate the folders from directly inside the Sound Font listing. 
  • You can load up to 16 sound fonts on your 16 midi channels.
  • On the second tab, you can set levels for gain/reverb/chorus.  
  • All control settings will be restored if you close and restart the app.

The interface is as simple as I could make it.  :-)

You'll need to setup fluidsynth first before using this gui.

In theory it should work on Windows, Mac and Linux (it just uses fluidsynth's socket interface).   I only have used it with xubuntu 14.04, FluidSynth version 1.1.6 so far.

Future/Planned Features ... ;-)

  • Add Checkbox that enables "More cowbell" 
  • Add new volume controls that go to "11" for extra "umph" when needed


On the other hand, if you only have one soundfont, you can use the existing GUI Qsynth instead.   In comparison, Qsynth looks like:

Though switching between soundfonts in Qsynth requires a few more steps.  You'll need to do this for every soundfont:

    Setup -> Soundfonts -> Open

1 comment:

KW said...

Excellent! I need to get this set up on my computer. I like the plans for cowbell too.