fluid-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[fluid-dev] Instrument names, selection etc. through the API


From: Nikhil Nair
Subject: [fluid-dev] Instrument names, selection etc. through the API
Date: Sun, 3 Aug 2014 12:41:36 +0100 (BST)
User-agent: Alpine 1.10 (DEB 962 2008-03-14)

Hi,

I'm very new to both FluidSynth and MIDI in general, and I'm working out
how to do the basics (play notes, change instruments etc.).  The playing
notes part is fine, as it's well described in the documentation as well as
in the example program that comes with libfluidsynth-dev.

I've installed (on Ubuntu) fluid-soundfont-gm, and have found the SF2 file
in /usr/share/sounds/sf2/.  I presume I just pass that full pathname to
fluid_synth_sfload() - that's fine.

When it comes to changing instrument, I presume I use
fluid_synth_program_change().  However, there seem to be a few facilities
missing: for instance, is there no way to find out the text name of an
instrument, given its number - and hence no way to search for an instrument
with a given name, without first knowing its number?  Even leaving aside
doing this through the API, there's nothing I can find in the Ubuntu
package in terms of a list of instrument names.

Do I assume all such SF2 files define all instruments in the range 0-127?
There doesn't seem to be a function to get the maximum instrument number in
a bank.  Or do I just assume the call to fluid_synth_program_change() will
return FLUID_FAILED if that particular instrument number isn't defined?

Am I missing something major here - or even a whole number of things?

Thanks,

Nikhil.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]