Byte arrays and MIDI - simple question?
Hi all, I've been looking through the Javax.sound.midi (for midi programming) package and found this:
public byte getMessage()
Obtains the MIDI message data. The first byte of the returned byte array is the status byte of the message. Any subsequent bytes up to the length of the message are data bytes. The byte array may have a length which is greater than that of the actual message; the total length of the message in bytes is reported by the getLength() method.
the byte array containing the complete MidiMessage data
What I would like to do is to get this MIDI message and obtain the second byte of the byte array, either by println on the screen or just to store the number in the variable (this second byte is the velocity/volume byte apparently).
If anyone has an idea how I could do this that'd be fantastic. Thank you.