Go Down

Topic: MIDI: What if you don't send noteOff? (Read 573 times) previous topic - next topic

zenwebb

Just a quick question for your MIDI gurus out there; what would happen if I send a series of "note on" events through MIDi to my synth (Ableton Live) but never send any note off messages? Is this akin to a memory leak?

If I'm only triggering drum samples and not pads (like strings or continuous tones) then would a sample play once for each note on message, then stop? Or would it continue to loop the sample over and over and over again?

Reason I'm asking is that I'd like to make a MIDI controller that does multiple drum sample triggering, but haven't figured out a way to send a note off message at some point in the future while I'm constantly polling my piezo sensors for data.
Grad student, creative technologist, OSHW engineer
http://jason-webb.info

Martin Gerken

I think that depends on the instrument - a hardware midi instrument will just cut the tone when reaching its voice limit.
You could send a an "all notes off" controll command.

nomuse

I'm guessing with Martin...for drum sounds you may not have a problem.  But I'm not sure why you can't work in the note-off command.  Actually...most drum sounds operate in a mode where they play the entire sample regardless of whether they get a note-off before they've finished.  So you could spend a little longer, and just send "note-on note-off" as a single message.  

My own silly little MIDI programs send note-off during the polling; how it works, is when I've sent a note-on event I also set a flag "Playing(noteNumber)"  Each time I poll the buttons, if the button is NOT pressed, AND the flag for that associated note IS set, I send a note-off.  

Anyhow...as long as you are just drums this won't matter, but the moment you add a bass or anything else that might be a continuous tone (timpani roll?) you will want to have the full MIDI spec running.

Go Up