I’m writing some modules and would like to implement polyphony. Using the dev sdk from the weekend and the matching runtime on my mac.
My question is: How do I generate a polyphonic signal? I did the simplest thing of hooking gate from the standard MIDI plugin to my input and getChannels() returns 1 even when I press 2 keys. Seems the MIDI input adapter isn’t polyphonic yet, or I’m missing something really really basic.
So for folks out there making their envelopes and oscillators polyphonic today, how do you generate polyphonic input signals? I see things like Fundamental/VCA already support poly so there must be a way I"m just missing. I think?
Yeah actually I have a less dumb question on polyphony also which is a design one.
Say I have an envelope generator with ADSR and a Gate. Fine. So obviously a polyphonic gate means you can do an envelope per voice. easy peasy.
But how are you suggesting we deal with polyphony on the parameters? Seems there’s three cases
1: Easy case: ADSR have a CV control with width 1; Gate has width N. Just copy at trigger time. Fine
2: Easy case: ADSR and Gate both have width N. Fine makes perfect sense as well.
3: But what if one of the CV inputs on A has a different channel count than the gates. What does that “mean” and how are modules defaulting to dealing with that?
See what I mean? If you’d prefer I can ask this someplace else too.
One “master” input should define the global channels of your process() function. Typically this is the most significant input, like “audio in” or “gate in” for envelope generators.
Use inputs[GATE_INPUT].getVoltage(c) for the “master” input and inputs[CV_INPUT].getPolyVoltage(c) for secondary inputs.
Same as above.
Same as above. If the CV input is poly, it will return 0 for channels it doesn’t have. If it’s mono, it will return the mono voltage for all c.