Determining the MidiInput source of a MidiMessage


It would be wonderful if there was a MidiMessageCollector that also stored the MidiInput source for each message so that messages could be routed according to the source. Maybe a void * in MidiMessage and a small patch to MidiMessageCollector::handleIncomingMidiMessage would do this?



Wouldn’t want to bloat MidiMessage with any extra data - I tried to keep it as a very lightweight structure. You could use more than one message collector for different inputs, perhaps?


Ahh, right. That’s a good idea. KISS, right?


KISS is a good idea in general, but particularly for things like MidiMessage, where you might have really large arrays of them knocking around.