midimute

collects 3 midi-streams into one. each stream can be muted. buttons 'muteNoteOnOnly' set whether all messages of an input stream or muted or only note-ons.
Author: Robert Schirmer
License: BSD
Github: rbrt/poly/midimute.axo

Inlets

bool32.risingfalling mute

bool32.risingfalling muteOnOnly

int32.positive note

int32.positive velo

Outlets

int32.positive note

int32.positive velo

Declaration
uint8_t note;
uint8_t velo;
uint8_t pnote;
uint8_t pvelo;
Control Rate
if (!inlet_mute) {
  note = inlet_note;
  velo = inlet_velo;
} else if ((!inlet_velo) && inlet_muteOnOnly) {
  note = inlet_note;
  velo = 0;
}

if ((note != pnote) || (velo != pvelo)) {
  pnote = note;
  pvelo = velo;
}

outlet_note = pnote;
outlet_velo = pvelo;

Privacy

© 2024 Zrna Research