3

I am writing a MIDI sequencer in C++ using asoundlib. Sometimes I would like my application to stop all voices, calling an All-Notes-Off event. I do it by calling a note-off to every note at every channel, since this is the only way I know, but for some reasons I am not really happy to send 16*128=2048 events in one moment. Is there any other approach to that? It would be perfect if I could send an event to the control queue, is there any? If not, then what is the way it should be done?

Any help is welcome, since the Internet lacks a good, detailed ALSA documentation.

1 Answer 1

1

According to the crash course on the midi specification you simply send an event 'Z' with an all notes off which is explained as 00 B0 7B 00

00 to indicate no time delay
B0 to send a midi control signal
7B to send an all notes off
00 does nothing (padding)

You can see a list of midi control bytes here: MIDI Controller Numbers

Happy hunting!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .