@ulrik
It does not work with stuck notes
Latest posts made by WillDevelop
-
RE: How to make a Panic Button (Send All MIDI Off)?
-
RE: How to make a Panic Button (Send All MIDI Off)?
@ulrik Nice, but after playing around with it a bit, I realized that you still have to press a midi Note to send the NoteOff commands
-
RE: How to make a Panic Button (Send All MIDI Off)?
@ulrik Yes it works but unfortunately only as a VST2 plugin
-
RE: How to make a Panic Button (Send All MIDI Off)?
Okay, my bad.
I have now solved the problem like this:
When you press the panic button you have one second to press any MIDI note so it can send a note off command to the next plugin for each note.Here is the code for it
onInit()
// MIDI Panic Btn const midiPanicBtn = Content.addButton("midiPanicBtn").setPosition(204, 40, 70, 43); var isMidiPanicBtnActive = midiPanicBtn.getValue; // MIDI Panic Btn Timer const midiPanicBtn_timer = Engine.createTimerObject(); midiPanicBtn_timer.setTimerCallback(function(){ var panicBtn = Content.getComponent("midiPanicBtn"); isMidiPanicBtnActive = 0; midiPanicBtn_timer.stopTimer(); });
Button-Callback
if(isMidiPanicBtnActive == 0) { isMidiPanicBtnActive = 1; midiPanicBtn_timer.startTimer(1000); }
onNoteOff()
if (isMidiPanicBtnActive == 1) { for(i=0; i<128; i++) { Console.print(i); Message.setNoteNumber(i); Message.sendToMidiOut(); } }
Thank you all for helping me!
-
RE: How to make a Panic Button (Send All MIDI Off)?
@Christoph-Hart said in How to make a Panic Button (Send All MIDI Off)?:
sendToMidiOut
That's a good suggestion, but when trying around with the MessageHolder object I noticed that the object does not have the function sendToMidiOut() at all and if I understand correctly sendToMidiOut() only works in the Midi callbacks, which is only triggered when a Midi signal comes in
-
RE: Set step size of button for pluginParameter ?
@d-healey That's exactly my problem, but if it's due to HISE itself, then there's nothing you can do about it, right?
It's not that bad anyway@d-healey said in Set step size of button for pluginParameter ?:
The problem is on the HISE end I believe
-
RE: How to make a Panic Button (Send All MIDI Off)?
@johnmike that would be a much simpler solution, but I found nothing in the documentation about project master bypass.
-
RE: How to make a Panic Button (Send All MIDI Off)?
I have found a solution
Button Callback
if(isMidiPanicBtnActive == 0) { isMidiPanicBtnActive = button.getValue; button.setValue(0); }
onNoteOff Callback
if (isMidiPanicBtnActive == 1) { for(i=0; i<128; i++) { Message.setNoteNumber(i); Message.sendToMidiOut(); } isMidiPanicBtnActive = 0; }
The only downside of this solution is that you have to press the button and then press a midi key
Because I don't think it is possible to send a message command with a button click, at least not "Message.setNoteNumber()" -
RE: How to make a Panic Button (Send All MIDI Off)?
@Lindon Okay, I tried it and it didn't work.
-
RE: How to make a Panic Button (Send All MIDI Off)?
@Lindon
But does it also send a Note Off command to another plugin?
Because the plugin does not generate its own sounds, but only outputs MIDI data.