Search in sources :

Example 1 with IApplication

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

the class MasterMode method updateDisplay.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay() {
    if (!this.surface.getConfiguration().hasDisplay1())
        return;
    this.drawDisplay2();
    final Display d = this.surface.getDisplay().clear();
    final String projectName = StringUtils.fixASCII(this.model.getProject().getName());
    final IMasterTrack master = this.model.getMasterTrack();
    final IApplication application = this.model.getApplication();
    d.setCell(0, 0, "Volume").setCell(0, 1, "Pan").setBlock(0, 1, "Audio Engine:").setCell(0, 4, application.isEngineActive() ? " On" : " Off");
    d.setCell(0, 5, "Prjct:").setBlock(0, 3, projectName);
    d.setCell(1, 0, master.getVolumeStr(6)).setCell(1, 1, master.getPanStr(6)).setBlock(1, 1, application.isEngineActive() ? "  Turn off" : "  Turn on");
    d.setCell(1, 6, " <<").setCell(1, 7, " >>").allDone();
}
Also used : IApplication(de.mossgrabers.framework.daw.IApplication) IMasterTrack(de.mossgrabers.framework.daw.data.IMasterTrack) Display(de.mossgrabers.framework.controller.display.Display)

Example 2 with IApplication

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

the class FrameMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final IApplication app = this.model.getApplication();
    final Display d = this.surface.getDisplay();
    d.setRow(0, FrameMode.ROW0).setRow(1, FrameMode.ROW1).setRow(2, app.isArrangeLayout() ? FrameMode.ARRANGER_ROW2 : app.isMixerLayout() ? FrameMode.MIXER_ROW2 : FrameMode.EMPTY).setRow(3, app.isArrangeLayout() ? FrameMode.ARRANGER_ROW3 : app.isMixerLayout() ? FrameMode.MIXER_ROW3 : FrameMode.EMPTY);
}
Also used : IApplication(de.mossgrabers.framework.daw.IApplication) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Example 3 with IApplication

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

the class AddTrackCommand method execute.

/**
 * {@inheritDoc}
 */
@Override
public void execute(final ButtonEvent event) {
    if (event != ButtonEvent.DOWN)
        return;
    IChannelBank tb = this.model.getTrackBank();
    final IApplication application = this.model.getApplication();
    if (this.surface.isShiftPressed()) {
        application.addEffectTrack();
        tb = this.model.getEffectTrackBank();
    } else if (this.surface.isSelectPressed())
        application.addAudioTrack();
    else
        application.addInstrumentTrack();
    final IChannelBank bank = tb;
    this.surface.scheduleTask(() -> {
        final int pos = bank.getTrackCount() - 1;
        bank.scrollToChannel(pos);
        bank.getTrack(pos % bank.getNumTracks()).select();
    }, 200);
}
Also used : IApplication(de.mossgrabers.framework.daw.IApplication) IChannelBank(de.mossgrabers.framework.daw.IChannelBank)

Example 4 with IApplication

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

the class FrameMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1(final ITextDisplay display) {
    final IApplication app = this.model.getApplication();
    final String[] rows34;
    if (app.isArrangeLayout())
        rows34 = FrameMode.ARRANGER_ROWS;
    else if (app.isMixerLayout())
        rows34 = FrameMode.MIXER_ROWS;
    else
        rows34 = FrameMode.EMPTY_ROWS;
    display.setRow(0, FrameMode.ROW0).setRow(1, FrameMode.ROW1).setRow(2, rows34[0]).setRow(3, rows34[1]);
}
Also used : IApplication(de.mossgrabers.framework.daw.IApplication)

Example 5 with IApplication

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

the class MasterMode method updateDisplay.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay() {
    if (!this.surface.getConfiguration().hasDisplay1())
        return;
    this.drawDisplay2();
    final ITextDisplay d = this.surface.getTextDisplay().clear();
    final String projectName = StringUtils.fixASCII(this.model.getProject().getName());
    final IMasterTrack master = this.model.getMasterTrack();
    final IApplication application = this.model.getApplication();
    d.setCell(0, 0, "Volume").setCell(0, 1, "Pan").setBlock(0, 1, "Audio Engine:").setCell(0, 4, application.isEngineActive() ? " On" : " Off");
    d.setCell(0, 5, "Prjct:").setBlock(0, 3, projectName);
    d.setCell(1, 0, master.getVolumeStr(6)).setCell(1, 1, master.getPanStr(6)).setBlock(1, 1, application.isEngineActive() ? "  Turn off" : "  Turn on");
    d.setCell(1, 6, " <<").setCell(1, 7, " >>").allDone();
}
Also used : IApplication(de.mossgrabers.framework.daw.IApplication) ITextDisplay(de.mossgrabers.framework.controller.display.ITextDisplay) IMasterTrack(de.mossgrabers.framework.daw.data.IMasterTrack)

Aggregations

IApplication (de.mossgrabers.framework.daw.IApplication)15 IArranger (de.mossgrabers.framework.daw.IArranger)5 IMixer (de.mossgrabers.framework.daw.IMixer)4 IChannelBank (de.mossgrabers.framework.daw.IChannelBank)3 Display (de.mossgrabers.framework.controller.display.Display)2 ITransport (de.mossgrabers.framework.daw.ITransport)2 IMasterTrack (de.mossgrabers.framework.daw.data.IMasterTrack)2 ITrack (de.mossgrabers.framework.daw.data.ITrack)2 PushDisplay (de.mossgrabers.push.controller.PushDisplay)2 MaschineJamConfiguration (de.mossgrabers.controller.ni.maschine.jam.MaschineJamConfiguration)1 SessionView (de.mossgrabers.controller.ni.maschine.jam.view.SessionView)1 UnknownCommandException (de.mossgrabers.controller.osc.exception.UnknownCommandException)1 Configuration (de.mossgrabers.framework.configuration.Configuration)1 ITextDisplay (de.mossgrabers.framework.controller.display.ITextDisplay)1 ICursorDevice (de.mossgrabers.framework.daw.ICursorDevice)1 ISceneBank (de.mossgrabers.framework.daw.ISceneBank)1 ITrackBank (de.mossgrabers.framework.daw.ITrackBank)1 ICursorDevice (de.mossgrabers.framework.daw.data.ICursorDevice)1 ITrackBank (de.mossgrabers.framework.daw.data.bank.ITrackBank)1 ViewManager (de.mossgrabers.framework.featuregroup.ViewManager)1