[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [fluid-dev] Channel handling
From: |
Tom M. |
Subject: |
Re: [fluid-dev] Channel handling |
Date: |
Tue, 02 Jan 2018 14:27:16 +0100 |
> I think what would be best is having each note class on its own channel.
fluidsynth only allows to render midi channel(s) to dedicated audio channel(s),
the so called multichannel-rendering. To me your problem of
note-to-audio-channel-rendering sounds very custom and I cannot think of a way
integrating this feature into fluidsynth without making synthing and mixing
more complicated, memory-hungry and exposing more complexity via the API to the
user.
I think this problem is best to be solved by using fluidsynth's API to
interfere the midi events and keeping track of the note on / off events that
are sent to the synth by modifying the midi channel of those events
accordingly. new_fluid_midi_driver() and new_fluid_midi_router() allow you to
specify your own custom midi processing function that could take care of that.
Finally you would need to pull out the audio using fluid_synth_nwrite_float(),
that would give you the separate stereo outputs rendered for midi channels
1,2,3,...
Tom