cc thin

Midi controller output, automatic thinning. Sends to midi/in/* objects only.
Author: Johannes Taelman
License: BSD
Github: midi/intern/cc thin.axo

Inlets

frac32.positive value

Outlets

None

Attributes

spinner channel

spinner cc

Declaration
int32_t lsend;
int timer;
Init
timer = 0;
Control Rate
if (((lsend > inlet_v + (1 << 19)) || (inlet_v > lsend + (1 << 19))) &&
    (timer > 30)) {
  lsend = inlet_v;
  PatchMidiInHandler(MIDI_DEVICE_INTERNAL, 0,
                     MIDI_CONTROL_CHANGE + (attr_channel - 1), attr_cc,
                     __USAT(inlet_v >> 20, 7));
  timer = 0;
} else
  timer++;

Privacy

© 2024 Zrna Research