Creating MIDI output with running status


#1

I noticed another tread on the topic of MIDI running status but it seems mostly concered with MIDI input, not output. Jules said:

"it's not actually possible to create a MidiMessage from data that has a missing status byte, so you can safely assume that it must have been handled"

Does that mean it's not possible for me to create an output stream that uses running status for faster output? Or maybe it's automatically created by juce dropping the redundant bits?


#2

This is not possible at the moment. JUCE will compute the length of the MIDI message from the first byte of the message. With running status there is no way of predicting the length of the midi message from only the first byte.


#3

FWIW definitely the best way of actually implementing running status would be for the midi output class (or device) to apply it where possible as an optimisation to the outgoing stream of data. It would be silly if you had to write code that kept track of the messages you send and modify them, not to mention this being a problem if multiple threads were writing to the same device.


#4

Thanks. I'll keep this in mind.