bitfocus / companion-module-soundcraft-ui

MIT License
15 stars 6 forks source link

Add feedback for fader level comparison #19

Open fmalcher opened 4 years ago

fmalcher commented 4 years ago

First draft, not yet part of the module:

[FeedbackType.MasterChannelLevelCompare]: {
      label: 'Change colors for master channel level comparison',
      description: 'If fader level is greater/less than a given value, change color of the bank',
      options: [
        getBackgroundPicker(instance.rgb(0, 102, 0)),
        getForegroundPicker(instance.rgb(255, 255, 255)),
        ...OPTION_SETS.masterChannel,
        OPTIONS.faderValuesSlider,
        {
          type: 'dropdown',
          label: 'Compare',
          id: 'compare',
          choices: [
            { id: 1, label: 'greater than or equal' },
            { id: -1, label: 'less than or equal' }
          ],
          default: 1
        }
      ],
      callback: evt => {
        const compareValue = Number(evt.options.value);
        const faderValue = feedback.get(evt.id);
        const compareFactor = Number(evt.options.compare)
        if (faderValue * compareFactor >= compareValue) {
          return getOptColors(evt);
        } else {
          return {};
        }
      },
      subscribe: evt => {
        const c = getMasterChannelFromOptions(evt.options, conn);
        feedback.connect(evt, c.faderLevelDB$);
      },
      unsubscribe: evt => feedback.unsubscribe(evt.id)
issue-label-bot[bot] commented 4 years ago

Issue-Label Bot is automatically applying the label feature_request to this issue, with a confidence of 0.90. Please mark this comment with :thumbsup: or :thumbsdown: to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

obbau commented 1 year ago

Is there any progress on this? I have a ui16 and really would like to have companion feedback to show the current fader level.

fmalcher commented 1 year ago

No. These were the first experiments and I felt that feedbacks for a fader level comparison are not super useful.