< Back to IRCAM Forum

Microtonality in FluidSynth

Good morning,

Having begun working with OM and having got to grips with FluidSynth, I can’t seem to get it to play microtonally.

Would it be possible for someone to give me a clear guide as to what I need to do to enable this please?

I’m using OM 7.4, if that helps.

Many thanks,

Phil

Dear Phil,

It is the same as for midi see here:

The patch:
fluid-tutorial-10.omp (34.5 KB)
Note that you are using a beta 7.4 version, in the upcoming 7.4 version (very soon), it willl be even simpler.

Best
k

Dear Karim,

With the upgrade to Osx Sonoma, the fluidsynth object for Max seems to be broken, which means I cannot use the patch r-udp-player, which I developed any more.
It is great to see that Fluidsynth is now integrated with OM, and I got it playing with your tutorial patch. Since the tutorial patch you uploaded is numbered 10, is there a series of fluidsynth tutorials which could help grasp the new system better?

What I would like is an orchestral setup (like I had with r-udp-player): Channel 1 is flute, channel 2 is oboe, while microtonal divisions are handled within each channel. In my app, each channel (instrument) would mean a new instance of fluidsynth, where each contain the necessary number of channels to split microtones into different pitchbends. I have not yet grasped how to play different instances of fluidsynth from OM.

Also, there seems to be a challenge selecting more than 20 sf2-files, as I cannot find a scroll-bar in the “SF2 Port Setup” (OM 7.4 Osx Sonoma). I would perhaps need to change the screen size for this, because I cannot expand the window past port 19.

Hope you can help, I have not followed all recent developments with OM, and I’m trying to catch up.

Best
Ruben

Dear Ruben,

First about the tutorial 10. This one is just a copy of the om tutorial Nr.10. But thanks for your question, this eventually pushes me to do a fluid special help patches that i will provide in the upcpming version 7.5

Now concerning polyphony, this is how it works here (i don’t know if this is the optimal and logical best way, i am opened to any suggestion):

You can create as much fluid instances as your RAM allows. Each of them will use a port starting from port 0. So each instance has its own 16 channels that you can set. In the next version there is also very new features regarding microtones. We have implemented with the great help of Steven Socha most of the EDO scales. You will have also the autotune feature.

Concerning the SF2 Port Setup, yes it is somehow not really debugged. Still working on it. However, i beleive i added the scrollbar but will check. Thank you for the report.

Best Regards
karim

1 Like

Ok just checked about the sf2 setup with no scrollbar. Indeed. There is no scrollbar.

Will fix this. Thanx for the report

Best
K

I was not aware of the port parameter in the score objects. I can select all notes in the editor, and change the port, and it plays to the next instance. It would be useful to make a function like “apply-ports-to-poly” where you have a list of voices and a list of port numbers. But I’m not sure how to do that, as there are no port inputs to the classes.

Take a look to the Functions->Score-> Score Functions->set-obj-port

:slight_smile:
K

Thanks, set-obj-port works well!

But, now I’m having trouble getting Fluidsynth playing again. In Fluidsynth preferences, 20 synths are loaded, and Fluidsynth is selected in MIDI settings. Still, under PortMIDI setup, all 20 ports are disconnected. I’m not sure how I was lucky to get them online earlier. I can see in the terminal that Fluidsynth is still installed. When playing a score ocbject with Fluidsynth selected, I get this error:

I would be good to find a way of having everything connected each time OM starts, and also have the correct 20 sf2-files selected.

I tried to do something with fluid-synth-console, but I’m not using it correctly:

When evaluating this, I can open and close the patch. But after I restart OM, the patch cannot be opened again:

Skjermbilde 2024-10-22 kl. 22.05.51

I managed to break 3 patches this way.

Sorry about that.
This is hopefully fixed in the upcoming version 7.5 to be released pretty soon.
Do you care to test the beta version?
If yes, what Mac are you running? M1 or Intel?

BEst
K

It’s Intel, Sonoma, still version 7.4. I may try the beta version.

Best
Ruben

Hi,
Is the tutorial for fluidsynth still valid for OM7.5?
Thanks,
Jimmie

Yes it is still valid, but in progress :slight_smile:
Why? did you happen to notice some issues?

Best
K

Hi Karim, and thanks for your response.
Actually, I just tried now to use the settings Autoload Synths and Auto Microtune, in the Fluidsynth settings, restarted OM, and I see that everything is configured automatically without the need to evaluate the fluid-pitchwheel, which for my own usage is just fine.

However, I do have three other questions :

  • In the Fluidsynth console (see image), I don’t seem to have much instrument options in the scrolling menu on top, is it normal?
  • When I use another channel than 1, the microtonality seems all messed up, even when the same edo tuning is selected?
  • And this should be related, but still on the image, it seems that the default edo tunings are erratic at some point, since here you see 5 edo for the first, but on playback it works properly in 48 edo?

Dear Jimmie,

For the first issue, ie instruments displayed, this will depend on the soudfont you loaded. Did you load the default soundfont, or is it a soundfont you are using. Some soundfonts have only few instrument. Others a lot more. So in principle, the console will take into account the instrument’s name you have loaded.

Second issue, Yes, there seems to be some inconsistency here. If you use Auto Microtune you shouldn’t car about tuning in the console. I am not sure if this works. However, please do experiment, since the auto microtune is a new feature which takes into account the score editor EDO tuning. So if you set another tuning in the console, for sure this will override it.

Hope this helps.

Best
K

Thanks Karim, I’ll tell you if I experiment any other issue.
As for the soundfont, you mention a default one, which one is it exactly, and where should we find it?
Best,
Jimmie

First of all, can you tell me which os/OM distribution you are using?
Since the soundfont is delivered in your distribution. the location will depend on your OS.

You can also find it here:

Best
K

Thanks for the merlin file, I will look at it closely!
I’m using MAC OS Sonoma (14.7.1) on a M3 Pro macbook.
Best,
Jimmie