use of de.mossgrabers.controller.ni.kontrol.mki.command.continuous.MainEncoderCommand in project DrivenByMoss by git-moss.
the class Kontrol1ControllerSetup method registerContinuousCommands.
/**
* {@inheritDoc}
*/
@Override
protected void registerContinuousCommands() {
final Kontrol1ControlSurface surface = this.getSurface();
final IMidiInput input = surface.getMidiInput();
for (int i = 0; i < 8; i++) {
final IHwRelativeKnob knob = this.addRelativeKnob(ContinuousID.get(ContinuousID.KNOB1, i), "Knob " + (i + 1), new KnobRowModeCommand<>(i, this.model, surface), Kontrol1ControlSurface.ENCODER_1 + i);
knob.bindTouch(new KnobRowTouchModeCommand<>(i, this.model, surface), input, BindType.CC, 0, Kontrol1ControlSurface.TOUCH_ENCODER_1 + i);
knob.setIndexInGroup(i);
}
this.addRelativeKnob(ContinuousID.MASTER_KNOB, "Master", new MainEncoderCommand(this.model, surface), Kontrol1ControlSurface.MAIN_ENCODER);
surface.addPianoKeyboard(25, input, true);
}
Aggregations