I'm working on a patch to visualize MIDI notes received from outside Max.
This is what I did:
It uses cycle~ and jit.poke~ to generate a nice "wobblying" mask for vertical bars generated with jit.fill
It works pretty well, but I think it's quite CPU-heavy. If I try to set up a "multichannel" version, in which the MIDI section of the patch goes into a poly~ object and every MIDI channel generates different colors, I notice a dramatic framerate drop with three or four active MIDI channels, so it reduces its potentiality for my purposes.
So I was guessing if there was a more efficient way to obtain this visual effect, for example generating the "spectrogram" in pure Jitter, without the need to use fft, or if there is some bottleneck in the "MIDI to jit.fill" part, which I don't see.
Any help is appreciated