Search in sources :

Example 56 with IParameter

use of de.mossgrabers.framework.daw.data.IParameter in project DrivenByMoss by git-moss.

the class DeviceHandler method handleParameter.

private void handleParameter(final KnobMode knobMode, final int index, final MidiValue value) {
    final IParameter fxParam = this.model.getCursorDevice().getParameterBank().getItem(index);
    final int val = value.getValue();
    if (isAbsolute(knobMode))
        fxParam.setValue(this.getAbsoluteValueChanger(value), val);
    else
        fxParam.changeValue(this.getRelativeValueChanger(knobMode), val);
}
Also used : IParameter(de.mossgrabers.framework.daw.data.IParameter)

Example 57 with IParameter

use of de.mossgrabers.framework.daw.data.IParameter in project DrivenByMoss by git-moss.

the class FxTrackHandler method changeTrackPanorama.

private void changeTrackPanorama(final KnobMode knobMode, final int trackIndex, final MidiValue value) {
    final Optional<ITrack> track = this.getTrack(trackIndex);
    if (track.isEmpty())
        return;
    final IParameter panParameter = track.get().getPanParameter();
    final int val = value.getValue();
    if (isAbsolute(knobMode))
        panParameter.setValue(this.getAbsoluteValueChanger(value), val);
    else
        panParameter.changeValue(this.getRelativeValueChanger(knobMode), val);
}
Also used : IParameter(de.mossgrabers.framework.daw.data.IParameter) ITrack(de.mossgrabers.framework.daw.data.ITrack)

Example 58 with IParameter

use of de.mossgrabers.framework.daw.data.IParameter in project DrivenByMoss by git-moss.

the class MasterHandler method changeMasterPanorama.

private void changeMasterPanorama(final KnobMode knobMode, final MidiValue value) {
    final ITrack track = this.model.getMasterTrack();
    final int val = value.getValue();
    final IParameter panParameter = track.getPanParameter();
    if (isAbsolute(knobMode))
        panParameter.setValue(this.getAbsoluteValueChanger(value), val);
    else
        panParameter.changeValue(this.getRelativeValueChanger(knobMode), val);
}
Also used : IParameter(de.mossgrabers.framework.daw.data.IParameter) ITrack(de.mossgrabers.framework.daw.data.ITrack)

Example 59 with IParameter

use of de.mossgrabers.framework.daw.data.IParameter in project DrivenByMoss by git-moss.

the class MasterHandler method changeMasterVolume.

private void changeMasterVolume(final KnobMode knobMode, final MidiValue value) {
    final ITrack track = this.model.getMasterTrack();
    final int val = value.getValue();
    final IParameter volumeParameter = track.getVolumeParameter();
    if (isAbsolute(knobMode))
        volumeParameter.setValue(this.getAbsoluteValueChanger(value), val);
    else
        volumeParameter.changeValue(this.getRelativeValueChanger(knobMode), val);
}
Also used : IParameter(de.mossgrabers.framework.daw.data.IParameter) ITrack(de.mossgrabers.framework.daw.data.ITrack)

Example 60 with IParameter

use of de.mossgrabers.framework.daw.data.IParameter in project DrivenByMoss by git-moss.

the class ShuffleView method getNumber.

/**
 * {@inheritDoc}}
 */
@Override
protected int getNumber() {
    final int max = this.model.getValueChanger().getUpperBound() - 1;
    final IParameter parameter = this.model.getGroove().getParameter(GrooveParameterID.SHUFFLE_AMOUNT);
    return parameter == null ? 0 : (int) (parameter.getValue() * 100.0 / max);
}
Also used : IParameter(de.mossgrabers.framework.daw.data.IParameter)

Aggregations

IParameter (de.mossgrabers.framework.daw.data.IParameter)76 ICursorDevice (de.mossgrabers.framework.daw.data.ICursorDevice)17 IParameterBank (de.mossgrabers.framework.daw.data.bank.IParameterBank)14 ITrack (de.mossgrabers.framework.daw.data.ITrack)9 ITextDisplay (de.mossgrabers.framework.controller.display.ITextDisplay)6 ICursorDevice (de.mossgrabers.framework.daw.ICursorDevice)6 IGroove (de.mossgrabers.framework.daw.IGroove)5 Display (de.mossgrabers.framework.controller.display.Display)4 IValueChanger (de.mossgrabers.framework.controller.valuechanger.IValueChanger)4 IParameterPageBank (de.mossgrabers.framework.daw.data.bank.IParameterPageBank)4 PushDisplay (de.mossgrabers.push.controller.PushDisplay)4 ITransport (de.mossgrabers.framework.daw.ITransport)3 IDeviceBank (de.mossgrabers.framework.daw.data.bank.IDeviceBank)3 PushConfiguration (de.mossgrabers.controller.ableton.push.PushConfiguration)2 TitleValueComponent (de.mossgrabers.controller.akai.fire.graphics.canvas.component.TitleValueComponent)2 FlexiHandlerException (de.mossgrabers.controller.generic.flexihandler.utils.FlexiHandlerException)2 FaderConfig (de.mossgrabers.controller.ni.maschine.jam.controller.FaderConfig)2 SLMkIIIDisplay (de.mossgrabers.controller.novation.slmkiii.controller.SLMkIIIDisplay)2 Configuration (de.mossgrabers.framework.configuration.Configuration)2 IGraphicDisplay (de.mossgrabers.framework.controller.display.IGraphicDisplay)2