Here's a quick demo of my midipolyphonic synth using discrete summation synthesis, and some thoughts

https://youtu.be/8AcBAnYGK1s
midiguipolyphonicvideox265cavol1 2

This is a midi polyphonic synth wrapped around the moorer discrete summation synthesis technique. Different parameters of the synth are mapped to a mouse and midi rotary controller abstraction. I wrote this because I was getting annoyed with testing out synth defs but having to manually tweak numbers everywhere, so wanted an easy way of having a performance oriented method of running a synthdef.

One of the things I’ve found going through the supercollider docs was there’s an implicit way of using synths, which is to have a Pattern binding and have synths instantiated per note. This paradigm is repeated throughout various articles and howtos. But, most traditional modular synthesists have discrete modules that run all the time, and there’s little easy methods of doing midi polyphony with voice stealing. You have to roll your own, so here’s some of my notes.

Envelopes can have variable attack,decay,etc. For some reason, I’ve always had the impression this wasn’t the case, but it turns out you can use a bus.control and map it to envelope parameters to control adsr.

Symbols are not strings. Using Dictionary, the keys can be symbols or strings, but if they’re printed out, it looks totally the same, except when you’re trying to retrieve using a string but it’s stored as a symbol instead.

Managing polyphony can be a little tricky. One idea was, if there are 5 voices, set up a program counter to point to the next available voice, and advance as keys are pressed, but keys are released at any time. The thing to note is once a key is released, the voice is still playing till the end of the release phase, but the problem is supercollider doesn’t have the ability to tell if the envelope is done. The doneaction can remove the entire synth, but for long running synths this isn’t useful because there isn’t a way to do a callback into the midi function that is handling incoming midi notes. To have this work, the voice allocation algorithm needs to evict the first note in a fifo queue of released voices or steal from a queue of already allocated voices if all voices are used.

Hope this helps if anyone is trying to do this.

1 Like