fluid-dev
[Top][All Lists]
Advanced

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

Re: [fluid-dev] MIDI bank select problems


From: Element Green
Subject: Re: [fluid-dev] MIDI bank select problems
Date: Thu, 28 Nov 2013 11:51:25 -0700

Hello,

Looking at the SVN log, I see that it was Pedro Lopez-Cabanillas who added the synth.midi-bank-select setting and code.  Perhaps he has a better idea of what the "mma" mode is all about.  I'll see if I can be of any help though..


On Thu, Nov 28, 2013 at 7:38 AM, Chris Robinson <address@hidden> wrote:
Hello.

I'm toying around with adding a MIDI interface to OpenAL Soft, allowing applications to specify timestamped MIDI events for sample-perfect timing. I'm using FluidSynth to render the MIDI into my output buffer to get mixed in with all the other sounds. In general, it's all working splendidly.

In the interest of standardization, I'm forcing the synth to use "mma" bank select mode, which as far as I understand, conforms to General MIDI Level 2 <https://en.wikipedia.org/wiki/General_MIDI_Level_2>. I do this by setting



Did you see any information that indicated that "mma" mode was supposed to be GM2?

 
fluid_settings_setstr(self->Settings, "synth.midi-bank-select", "mma");

before calling

self->Synth = new_fluid_synth(self->Settings);

When I do this, I find I'm not able to change the bank used by channel 9 (0-based counting). According to the above wikipedia entry, it's supposed to be possible to use all 16 channels for melodic instruments, however when I try to change channel 9 to bank 0 via CC0 and CC32 messages (followed immediately by an appropriate program change), FluidSynth continues using bank 128 on channel 9.



What part of that Wikipedia article leads you to believe that channels 10 and 11 (9 and 10 as far as FluidSynth is concerned) can be switched to melodic with GM2?  I didn't see any mention either way.  It seems like that was intended though, since the drum banks are accessed on a separate Bank MSB.  Just trying to get things clarified in my own understanding.

 

Also, I'm confused about what exactly I'm supposed to specify to change the bank. According to FluidSynth's wiki, <http://sourceforge.net/apps/trac/fluidsynth/wiki/FluidSettings>, 'mma' selects a bank according to the math:

CC0*128 + CC32

However, according to the GM2 wikipedia page, "General MIDI 2 compatible synthesizers access all of the 256 instruments by setting cc#0 (Bank Select MSB) to 121 and using cc#32 (Bank Select LSB) to select the variation bank before a Program Change. Variation bank 0 contains full GM sound set." which says that to set an instrument from melodic bank 0, you set CC0 to 121 and CC32 to 0, followed by a program change for the wanted instrument.

Additionally, selecting a drum bank is done by setting CC0 to 120 and CC32 to 0, then a program change for the wanted drum kit. This doesn't at all follow the math detailed above.

In any case, I've tried setting CC0=0 + CC32=0 and CC0=121 + CC32=0, and both result in FluidSynth continuing to use bank 128 on channel 9.


Am I doing something wrong, or misunderstanding something? Thanks for any help you can provide.



At this point, I'm also confused.  Perhaps Pedro will chime in to help clarify the original intent of "mma" bank select mode.  It may be that it was intended to be something completely different than GM2 mode, in which case a "gm2" option could be added.


Best regards,

Element Green


reply via email to

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