Search in sources :

Example 11 with Display

use of de.mossgrabers.framework.controller.display.Display in project DrivenByMoss by git-moss.

the class MasterMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final Display d = this.surface.getDisplay();
    final IMasterTrack master = this.model.getMasterTrack();
    d.setRow(0, MasterMode.PARAM_NAMES).setCell(1, 0, master.getVolumeStr(8)).setCell(1, 1, master.getPanStr(8));
    d.clearCell(1, 2).clearCell(1, 3).setBlock(1, 2, "Audio Engine").setBlock(1, 3, this.model.getProject().getName()).done(1);
    d.setCell(2, 0, this.surface.getConfiguration().isEnableVUMeters() ? master.getVu() : master.getVolume(), Format.FORMAT_VALUE);
    d.setCell(2, 1, master.getPan(), Format.FORMAT_PAN).clearCell(2, 2).clearCell(2, 3).clearCell(2, 4).clearCell(2, 5).clearCell(2, 6).clearCell(2, 7).done(2);
    d.setCell(3, 0, master.getName()).clearCell(3, 1).clearCell(3, 2).clearCell(3, 3).setCell(3, 4, this.model.getApplication().isEngineActive() ? "Active" : "Off");
    d.clearCell(3, 5).setCell(3, 6, "Previous").setCell(3, 7, "Next").done(3);
}
Also used : IMasterTrack(de.mossgrabers.framework.daw.data.IMasterTrack) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Example 12 with Display

use of de.mossgrabers.framework.controller.display.Display in project DrivenByMoss by git-moss.

the class SendMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final Display d = this.surface.getDisplay();
    final int sendIndex = this.getCurrentSendIndex();
    final IChannelBank tb = this.model.getCurrentTrackBank();
    for (int i = 0; i < 8; i++) {
        final ITrack t = tb.getTrack(i);
        if (t.doesExist()) {
            final ISend send = t.getSend(sendIndex);
            d.setCell(0, i, send.getName());
            d.setCell(1, i, send.getDisplayedValue(8));
            d.setCell(2, i, send.getValue(), Format.FORMAT_VALUE);
        } else
            d.clearColumn(i);
    }
    d.done(0).done(1).done(2);
    this.drawRow4();
}
Also used : ITrack(de.mossgrabers.framework.daw.data.ITrack) IChannelBank(de.mossgrabers.framework.daw.IChannelBank) ISend(de.mossgrabers.framework.daw.data.ISend) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Example 13 with Display

use of de.mossgrabers.framework.controller.display.Display in project DrivenByMoss by git-moss.

the class NoteViewSelectMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final Display d = this.surface.getDisplay();
    final ViewManager viewManager = this.surface.getViewManager();
    d.clear().setBlock(1, 0, "Note view:");
    for (int i = 0; i < VIEWS.length; i++) {
        if (VIEWS[i] != null) {
            final View view = viewManager.getView(VIEWS[i]);
            d.setCell(3, i, view == null ? "" : (viewManager.isActiveView(VIEWS[i]) ? PushDisplay.RIGHT_ARROW : "") + view.getName());
        }
        if (VIEWS_TOP[i] != null)
            d.setCell(0, i, (viewManager.isActiveView(VIEWS_TOP[i]) ? PushDisplay.RIGHT_ARROW : "") + viewManager.getView(VIEWS_TOP[i]).getName());
    }
    d.allDone();
}
Also used : ViewManager(de.mossgrabers.framework.view.ViewManager) View(de.mossgrabers.framework.view.View) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Example 14 with Display

use of de.mossgrabers.framework.controller.display.Display in project DrivenByMoss by git-moss.

the class SessionViewSelectMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final Display d = this.surface.getDisplay();
    final ViewManager viewManager = this.surface.getViewManager();
    d.clear().setBlock(1, 0, "Session view:");
    for (int i = 0; i < VIEWS.length; i++) {
        if (VIEWS[i] != null)
            d.setCell(3, i, (this.isSelected(viewManager, i) ? PushDisplay.RIGHT_ARROW : "") + VIEW_NAMES[i]);
    }
    d.allDone();
}
Also used : ViewManager(de.mossgrabers.framework.view.ViewManager) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Example 15 with Display

use of de.mossgrabers.framework.controller.display.Display in project DrivenByMoss by git-moss.

the class DeviceLayerMode method updateDisplay1.

/**
 * {@inheritDoc}
 */
@Override
public void updateDisplay1() {
    final Display d = this.surface.getDisplay().clear();
    final ICursorDevice cd = this.model.getCursorDevice();
    if (!cd.hasSelectedDevice()) {
        d.setBlock(1, 0, "           Select").setBlock(1, 1, "a device or press").setBlock(1, 2, "'Add Effect'...  ").allDone();
        return;
    }
    final boolean noLayers = cd.hasLayers() && cd.hasZeroLayers();
    if (noLayers) {
        d.setBlock(1, 1, "    Please create").setBlock(1, 2, cd.hasDrumPads() ? "a Drum Pad..." : "a Device Layer...");
    } else {
        final IChannel l = cd.getSelectedLayerOrDrumPad();
        if (l != null) {
            d.setCell(0, 0, "Volume").setCell(1, 0, l.getVolumeStr(8)).setCell(2, 0, this.surface.getConfiguration().isEnableVUMeters() ? l.getVu() : l.getVolume(), Format.FORMAT_VALUE);
            d.setCell(0, 1, "Pan").setCell(1, 1, l.getPanStr(8)).setCell(2, 1, l.getPan(), Format.FORMAT_PAN);
            final IChannelBank fxTrackBank = this.model.getEffectTrackBank();
            if (fxTrackBank == null) {
                for (int i = 0; i < 6; i++) {
                    final int pos = 2 + i;
                    final ISend send = l.getSend(i);
                    d.setCell(0, pos, send.getName()).setCell(1, pos, send.getDisplayedValue(8)).setCell(2, pos, send.getValue(), Format.FORMAT_VALUE);
                }
            } else {
                final boolean isFX = this.model.isEffectTrackBankActive();
                for (int i = 0; i < 6; i++) {
                    final ITrack fxTrack = fxTrackBank.getTrack(i);
                    final boolean isEmpty = isFX || !fxTrack.doesExist();
                    final int pos = 2 + i;
                    if (isEmpty) {
                        d.clearCell(0, pos);
                        d.clearCell(2, pos);
                    } else {
                        final ISend send = l.getSend(i);
                        d.setCell(0, pos, fxTrack.getName()).setCell(1, pos, send.getDisplayedValue(8));
                        d.setCell(2, pos, send.getValue(), Format.FORMAT_VALUE);
                    }
                }
            }
        }
    }
    this.drawRow4(d, cd);
}
Also used : IChannel(de.mossgrabers.framework.daw.data.IChannel) ITrack(de.mossgrabers.framework.daw.data.ITrack) IChannelBank(de.mossgrabers.framework.daw.IChannelBank) ISend(de.mossgrabers.framework.daw.data.ISend) ICursorDevice(de.mossgrabers.framework.daw.ICursorDevice) Display(de.mossgrabers.framework.controller.display.Display) PushDisplay(de.mossgrabers.push.controller.PushDisplay)

Aggregations

Display (de.mossgrabers.framework.controller.display.Display)53 PushDisplay (de.mossgrabers.push.controller.PushDisplay)22 IChannelBank (de.mossgrabers.framework.daw.IChannelBank)18 ITrack (de.mossgrabers.framework.daw.data.ITrack)18 ICursorDevice (de.mossgrabers.framework.daw.ICursorDevice)10 ISend (de.mossgrabers.framework.daw.data.ISend)6 IChannel (de.mossgrabers.framework.daw.data.IChannel)5 IMasterTrack (de.mossgrabers.framework.daw.data.IMasterTrack)4 IParameter (de.mossgrabers.framework.daw.data.IParameter)4 PushConfiguration (de.mossgrabers.push.PushConfiguration)4 SLDisplay (de.mossgrabers.sl.controller.SLDisplay)4 IBrowser (de.mossgrabers.framework.daw.IBrowser)3 IBrowserColumn (de.mossgrabers.framework.daw.data.IBrowserColumn)3 IBrowserColumnItem (de.mossgrabers.framework.daw.data.IBrowserColumnItem)3 ViewManager (de.mossgrabers.framework.view.ViewManager)3 IApplication (de.mossgrabers.framework.daw.IApplication)2 MCUConfiguration (de.mossgrabers.mcu.MCUConfiguration)2 IValueChanger (de.mossgrabers.framework.controller.IValueChanger)1 ICursorClip (de.mossgrabers.framework.daw.ICursorClip)1 ISceneBank (de.mossgrabers.framework.daw.ISceneBank)1