Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display Mod Encoder Values with Popup, Update Value Ranges in Menu's, Update Midi CC Value Range, Bug Fix for Midi CC Assignment in Automation Overview #636

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion docs/community_features.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ Here is a list of general improvements that have been made, ordered from newest
#### 3.7 - Mod Wheel
- ([#512]) Incoming mod wheel on non-MPE synths now maps to y axis

#### 3.8 - Visual Feedback on Value Changes with Mod Encoders and Increased Resolution for Value's in Menu's
- ([#636]) Changing parameter values with Mod (Gold) Encoders now displays a pop-up with the current value of the Parameter. The Menu's for Parameters and Patch Cables have also been adjusted to show the same value range as displayed with the Mod Encoders.
- This allows for better fine-tuning of values.
- The value range displayed is 0-50 for non-MIDI parameters and 0-127 for MIDI parameters.
- Note: In the Menu, if you wish to scroll through the parameter value range faster at an accelerated rate of +/- 5, hold Shift while turning the Select Encoder.

## 4. New Features Added

Here is a list of features that have been added to the firmware as a list, grouped by category:
Expand All @@ -58,7 +64,6 @@ Here is a list of features that have been added to the firmware as a list, group
- Default (DEFA) - the default Deluge clip type.
- Fill (FILL) - Fill clip. It appears orange/cyan on the status pads, and when triggered it will schedule itself to start at such a time that it _finishes_ at the start of the next loop. If the fill clip is longer than the remaining time, it is triggered immediately at a point midway through. The loop length is set by the longest playing clip, or by the total length of a section times the repeat count set for that section. **Limitation**: a fill clip is still subject to the one clip per instrument behavior of the Deluge. Fill clips can steal an output from another fill, but they cannot steal from a non-fill. This can lead to some fills never starting since a default type clip has the needed instrument. This can be worked around by cloning the instrument to an independent copy.


#### 4.1.4 - Catch Notes

- ([#221]) The normal behavior of the Deluge is to try to keep up with 'in progress' notes when instant switching between clips by playing them late. However this leads to glitches with drum clips and other percussive sounds. Changing this setting to OFF will prevent this behavior and *not* try to keep up with those notes, leading to smoother instant switching between clips.
Expand Down Expand Up @@ -197,6 +202,7 @@ Synchronization modes accessible through the "LFO SYNC" shortcut.
- Follow-up PR's:
- ([#347]) Added new automatable parameters
- ([#360]) Fixed interpolation bugs, added fine tuning for long presses, and added pad selection mode
- ([#636]) Updated Parameter Values displayed in Automation View to match Parameter Value Ranges displayed in the Menu's. E.g. instead of 0 - 128, it now displays 0 - 50 (except for Pan which now displays -25 to +25 and MIDI instrument clips which now display 0 - 127).

#### 4.3.6 - Set Probability By Row

Expand Down Expand Up @@ -390,4 +396,5 @@ This list includes all preprocessor switches that can alter firmware behaviour a
[#368]: https://github.com/SynthstromAudible/DelugeFirmware/pull/368
[#395]: https://github.com/SynthstromAudible/DelugeFirmware/pull/395
[#512]: https://github.com/SynthstromAudible/DelugeFirmware/pull/512
[#636]: https://github.com/SynthstromAudible/DelugeFirmware/pull/636
[Automation View Documentation]: https://github.com/SynthstromAudible/DelugeFirmware/blob/release/1.0/docs/features/automation_view.md
2 changes: 2 additions & 0 deletions docs/features/automation_view.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,9 @@ The Automation Editor **will:**
- enable you to quickly change parameters in focus for editing by turning select or using shift + shortcut pad
- enable you to view the current parameter value setting for the parameters that are currently automatable.
- illuminate each pad row according to the current value within the range of 0-128. E.g. bottom pad = 0-16, then 17-32, 33-48, 49-64, 65-80, 81-96, 97-112, 113-128)
> **Update** The values displayed in automation view have been updated to display the same value range displayed in the menu's for consistency across the Deluge UI. So instead of displaying 0 - 128, it now displays 0 - 50. Calculations in automation view are still being done based on the 0 - 128 range, but the display converts it to the 0 - 50 range.
- edit new or existing parameter automations on a per step basis, at any zoom level across the entire timeline. Each row in a step column corresponds to a range of values in the parameter value range (0-128) (see above). If you press the bottom row, the value will be set to 0. if you press the top row, the value will be set to 128. Pressing the rows in between increments/decrements the value by 18 (e.g. 0, 18, 36, 54, 72, 90, 108, 128).
> **Update** The values displayed in automation view have been updated to display the same value range displayed in the menu's for consistency across the Deluge UI. So instead of displaying 0 - 128, it now displays 0 - 50. Calculations in automation view are still being done based on the 0 - 128 range, but the display converts it to the 0 - 50 range.

![image](https://github.com/seangoodvibes/DelugeFirmware/assets/138174805/8cc7befa-9071-4bd3-ac3c-15049f69b250)

Expand Down
18 changes: 17 additions & 1 deletion src/definitions_cxx.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,23 @@ constexpr int32_t kNumPatchSources = static_cast<int32_t>(kLastPatchSource);
constexpr PatchSource kFirstLocalSource = PatchSource::ENVELOPE_0;
//constexpr PatchSource kFirstUnchangeableSource = PatchSource::VELOCITY;

//Automation Instrument Clip View constants
//Menu Min Max Values

//regular menu range e.g. 0 - 50
constexpr int32_t kMaxMenuValue = 50;
constexpr int32_t kMinMenuValue = 0;
constexpr int32_t kMidMenuValue = kMinMenuValue + ((kMaxMenuValue - kMinMenuValue) / 2);

//pan menu range e.g. -25 to +25
constexpr int32_t kMaxMenuPanValue = kMaxMenuValue / 2;
constexpr int32_t kMinMenuPanValue = -1 * kMaxMenuPanValue;

//patch cable menu range e.g. -5000 to 5000
constexpr int32_t kMaxMenuPatchCableValue = kMaxMenuValue * 100;
constexpr int32_t kMinMenuPatchCableValue = -1 * kMaxMenuPatchCableValue;
//

//Automation View constants
constexpr int32_t kNoSelection = 255;
constexpr int32_t kNumNonKitAffectEntireParamsForAutomation = 55;
constexpr int32_t kNumKitAffectEntireParamsForAutomation = 24;
Expand Down
4 changes: 2 additions & 2 deletions src/deluge/gui/menu_item/arpeggiator/midi_cv/gate.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ class Gate final : public Integer {
void readCurrentValue() override {
auto* current_clip = static_cast<InstrumentClip*>(currentSong->currentClip);
int64_t arp_gate = (int64_t)current_clip->arpeggiatorGate + 2147483648;
this->setValue((arp_gate * 50 + 2147483648) >> 32);
this->setValue((arp_gate * kMaxMenuValue + 2147483648) >> 32);
}
void writeCurrentValue() override {
(static_cast<InstrumentClip*>(currentSong->currentClip))->arpeggiatorGate =
(uint32_t)this->getValue() * 85899345 - 2147483648;
}
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
bool isRelevant(Sound* sound, int32_t whichThing) override { return soundEditor.editingCVOrMIDIClip(); }
};
} // namespace deluge::gui::menu_item::arpeggiator::midi_cv
7 changes: 4 additions & 3 deletions src/deluge/gui/menu_item/arpeggiator/midi_cv/rate.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,21 @@ class Rate final : public Integer {
using Integer::Integer;
void readCurrentValue() override {
this->setValue(
(((int64_t)(static_cast<InstrumentClip*>(currentSong->currentClip))->arpeggiatorRate + 2147483648) * 50
(((int64_t)(static_cast<InstrumentClip*>(currentSong->currentClip))->arpeggiatorRate + 2147483648)
* kMaxMenuValue
+ 2147483648)
>> 32);
}
void writeCurrentValue() override {
if (this->getValue() == 25) {
if (this->getValue() == kMidMenuValue) {
(static_cast<InstrumentClip*>(currentSong->currentClip))->arpeggiatorRate = 0;
}
else {
(static_cast<InstrumentClip*>(currentSong->currentClip))->arpeggiatorRate =
(uint32_t)this->getValue() * 85899345 - 2147483648;
}
}
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
bool isRelevant(Sound* sound, int32_t whichThing) override { return soundEditor.editingCVOrMIDIClip(); }
};
} // namespace deluge::gui::menu_item::arpeggiator::midi_cv
5 changes: 3 additions & 2 deletions src/deluge/gui/menu_item/audio_clip/attack.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,14 @@ class Attack final : public Integer {

void readCurrentValue() override {
this->setValue(
(((int64_t)(static_cast<AudioClip*>(currentSong->currentClip))->attack + 2147483648) * 50 + 2147483648)
(((int64_t)(static_cast<AudioClip*>(currentSong->currentClip))->attack + 2147483648) * kMaxMenuValue
+ 2147483648)
>> 32);
}
void writeCurrentValue() override {
(static_cast<AudioClip*>(currentSong->currentClip))->attack =
(uint32_t)this->getValue() * 85899345 - 2147483648;
}
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
};
} // namespace deluge::gui::menu_item::audio_clip
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/audio_clip/hpf_freq.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class HPFFreq final : public UnpatchedParam {

// 7SEG ONLY
void drawValue() override {
if (this->getValue() == 0) {
if (this->getValue() == kMinMenuValue) {
display->setText(l10n::get(l10n::String::STRING_FOR_DISABLED));
}
else {
Expand Down
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/audio_clip/lpf_freq.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class LPFFreq final : public UnpatchedParam {

// 7Seg ONLY
void drawValue() override {
if (this->getValue() == 50) {
if (this->getValue() == kMaxMenuValue) {
display->setText(l10n::get(l10n::String::STRING_FOR_DISABLED));
}
else {
Expand Down
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/filter/hpf_freq.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class HPFFreq final : public patched_param::IntegerNonFM {

// 7Seg ONLY
void drawValue() override {
if (this->getValue() == 0
if (this->getValue() == kMinMenuValue
&& !soundEditor.currentParamManager->getPatchCableSet()->doesParamHaveSomethingPatchedToIt(
::Param::Local::HPF_FREQ)) {
display->setText(l10n::get(l10n::String::STRING_FOR_DISABLED));
Expand Down
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/filter/lpf_freq.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class LPFFreq final : public patched_param::IntegerNonFM {

// 7Seg ONLY
void drawValue() override {
if (this->getValue() == 50
if (this->getValue() == kMaxMenuValue
&& !soundEditor.currentParamManager->getPatchCableSet()->doesParamHaveSomethingPatchedToIt(
::Param::Local::LPF_FREQ)) {
display->setText(l10n::get(l10n::String::STRING_FOR_DISABLED));
Expand Down
7 changes: 4 additions & 3 deletions src/deluge/gui/menu_item/midi/default_velocity_to_level.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,13 @@ namespace deluge::gui::menu_item::midi {
class DefaultVelocityToLevel final : public IntegerWithOff {
public:
using IntegerWithOff::IntegerWithOff;
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
void readCurrentValue() override {
this->setValue(((int64_t)soundEditor.currentMIDIDevice->defaultVelocityToLevel * 50 + 536870912) >> 30);
this->setValue(((int64_t)soundEditor.currentMIDIDevice->defaultVelocityToLevel * kMaxMenuValue + 536870912)
>> 30);
}
void writeCurrentValue() override {
soundEditor.currentMIDIDevice->defaultVelocityToLevel = this->getValue() * 21474836;
soundEditor.currentMIDIDevice->defaultVelocityToLevel = this->getValue() * (2147483648 / (kMaxMenuValue * 2));
currentSong->grabVelocityToLevelFromMIDIDeviceAndSetupPatchingForEverything(soundEditor.currentMIDIDevice);
MIDIDeviceManager::anyChangesToSave = true;
}
Expand Down
15 changes: 13 additions & 2 deletions src/deluge/gui/menu_item/osc/pulse_width.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,22 @@ class PulseWidth final : public menu_item::source::PatchedParam, public Formatte

[[nodiscard]] std::string_view getTitle() const override { return FormattedTitle::title(); }

int32_t getFinalValue() override { return (uint32_t)this->getValue() * (85899345 >> 1); }
int32_t getFinalValue() override {
if (this->getValue() == kMaxMenuValue) {
return 2147483647;
}
else if (this->getValue() == kMinMenuValue) {
return 0;
}
else {
return (uint32_t)this->getValue() * (2147483648 / kMidMenuValue) >> 1;
}
}

void readCurrentValue() override {
this->setValue(
((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) * 100 + 2147483648)
((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) * (kMaxMenuValue * 2)
+ 2147483648)
>> 32);
}

Expand Down
4 changes: 2 additions & 2 deletions src/deluge/gui/menu_item/param.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ namespace deluge::gui::menu_item {
class Param {
public:
Param(int32_t newP = 0) : p(newP) {}
[[nodiscard]] virtual int32_t getMaxValue() const { return 50; }
[[nodiscard]] virtual int32_t getMinValue() const { return 0; }
[[nodiscard]] virtual int32_t getMaxValue() const { return kMaxMenuValue; }
[[nodiscard]] virtual int32_t getMinValue() const { return kMinMenuValue; }
virtual uint8_t getP() { return p; };
MenuItem* selectButtonPress();
virtual ModelStackWithAutoParam* getModelStack(void* memory) = 0;
Expand Down
9 changes: 5 additions & 4 deletions src/deluge/gui/menu_item/patch_cable_strength.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ void PatchCableStrength::renderOLED() {

char buffer[12];
if (preferBarDrawing) {
int32_t rounded = (this->getValue() + 50 * (this->getValue() > 0 ? 1 : -1)) / 100;
int32_t rounded = this->getValue() / 100;
intToString(rounded, buffer, 1);
deluge::hid::display::OLED::drawStringAlignRight(
buffer, extraY + OLED_MAIN_TOPMOST_PIXEL + 4 + destinationDescriptor.isJustAParam(),
Expand Down Expand Up @@ -152,7 +152,7 @@ void PatchCableStrength::readCurrentValue() {
int32_t paramValue = patchCableSet->patchCables[c].param.getCurrentValue();
// the internal values are stored in the range -(2^30) to 2^30.
// rescale them to the range -5000 to 5000 and round to nearest.
this->setValue(((int64_t)paramValue * 5000 + (1 << 29)) >> 30);
this->setValue(((int64_t)paramValue * kMaxMenuPatchCableValue + (1 << 29)) >> 30);
}
}

Expand All @@ -175,8 +175,9 @@ void PatchCableStrength::writeCurrentValue() {
return;
}

// rescale from 5000 to 2**30. The magic constant is ((2^30)/5000), shifted 32 bits for precision ((1<<(30+32))/5000)
int32_t finalValue = ((int64_t)922337203685477 * this->getValue()) >> 32;
//rescale from 5000 to 2^30. The magic constant is ((2^30)/5000), shifted 32 bits for precision ((1<<(30+32))/5000)
int64_t magicConstant = (922337203685477 * 5000) / kMaxMenuPatchCableValue;
int32_t finalValue = (magicConstant * this->getValue()) >> 32;
modelStackWithParam->autoParam->setCurrentValueInResponseToUserInput(finalValue, modelStackWithParam);
}

Expand Down
4 changes: 2 additions & 2 deletions src/deluge/gui/menu_item/patch_cable_strength.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ class PatchCableStrength : public Decimal, public MenuItemWithCCLearning {
void beginSession(MenuItem* navigatedBackwardFrom) final;
void readCurrentValue() final;
void writeCurrentValue() override;
[[nodiscard]] int32_t getMinValue() const final { return -5000; }
[[nodiscard]] int32_t getMaxValue() const final { return 5000; }
[[nodiscard]] int32_t getMinValue() const final { return kMinMenuPatchCableValue; }
[[nodiscard]] int32_t getMaxValue() const final { return kMaxMenuPatchCableValue; }
[[nodiscard]] int32_t getNumDecimalPlaces() const final { return 2; }
virtual int32_t getDefaultEditPos() { return 2; }
MenuPermission checkPermissionToBeginSession(Sound* sound, int32_t whichThing, MultiRange** currentRange) override;
Expand Down
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/patch_cables.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ void PatchCables::renderOptions() {
}

int32_t param_value = cable->param.getCurrentValue();
int32_t level = ((int64_t)param_value * 5000 + (1 << 29)) >> 30;
int32_t level = ((int64_t)param_value * kMaxMenuPatchCableValue + (1 << 29)) >> 30;

floatToString((float)level / 100, buf + off + 5, 2, 2);
//fmt::vformat_to_n(buf + off + 5, 5, "{:4}", fmt::make_format_args();
Expand Down
18 changes: 12 additions & 6 deletions src/deluge/gui/menu_item/patched_param/integer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@

namespace deluge::gui::menu_item::patched_param {
void Integer::readCurrentValue() {
this->setValue((((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) + 2147483648) * 50
+ 2147483648)
>> 32);
this->setValue(
(((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) + 2147483648) * kMaxMenuValue
+ 2147483648)
>> 32);
}

void Integer::writeCurrentValue() {
Expand All @@ -35,10 +36,15 @@ void Integer::writeCurrentValue() {
}

int32_t Integer::getFinalValue() {
if (this->getValue() == 25) {
return 0;
if (this->getValue() == kMaxMenuValue) {
return 2147483647;
}
else if (this->getValue() == kMinMenuValue) {
return -2147483648;
}
else {
return (uint32_t)this->getValue() * (2147483648 / kMidMenuValue) - 2147483648;
}
return (uint32_t)this->getValue() * 85899345 - 2147483648;
}

} // namespace deluge::gui::menu_item::patched_param
14 changes: 9 additions & 5 deletions src/deluge/gui/menu_item/patched_param/pan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,21 @@ void Pan::drawValue() {
}

int32_t Pan::getFinalValue() {
if (this->getValue() == 32) {
if (this->getValue() == kMaxMenuPanValue) {
return 2147483647;
}
if (this->getValue() == -32) {
else if (this->getValue() == kMinMenuPanValue) {
return -2147483648;
}
return ((int32_t)this->getValue() * 33554432 * 2);
else {
return ((int32_t)this->getValue() * (2147483648 / (kMaxMenuPanValue * 2)) * 2);
}
}

void Pan::readCurrentValue() {
this->setValue(((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) * 64 + 2147483648)
>> 32);
this->setValue(
((int64_t)soundEditor.currentParamManager->getPatchedParamSet()->getValue(getP()) * (kMaxMenuPanValue * 2)
+ 2147483648)
>> 32);
}
} // namespace deluge::gui::menu_item::patched_param
4 changes: 2 additions & 2 deletions src/deluge/gui/menu_item/patched_param/pan.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ class Pan : public Integer {
void drawValue() override;

protected:
[[nodiscard]] int32_t getMaxValue() const override { return 32; }
[[nodiscard]] int32_t getMinValue() const override { return -32; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuPanValue; }
[[nodiscard]] int32_t getMinValue() const override { return kMinMenuPanValue; }
int32_t getFinalValue() override;
void readCurrentValue() override;
};
Expand Down
4 changes: 2 additions & 2 deletions src/deluge/gui/menu_item/reverb/compressor/shape.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ class Shape final : public Integer {
public:
using Integer::Integer;
void readCurrentValue() override {
this->setValue((((int64_t)AudioEngine::reverbCompressorShape + 2147483648) * 50 + 2147483648) >> 32);
this->setValue((((int64_t)AudioEngine::reverbCompressorShape + 2147483648) * kMaxMenuValue + 2147483648) >> 32);
}
void writeCurrentValue() override {
AudioEngine::reverbCompressorShape = (uint32_t)this->getValue() * 85899345 - 2147483648;
AudioEngine::mustUpdateReverbParamsBeforeNextRender = true;
}
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
bool isRelevant(Sound* sound, int32_t whichThing) override { return (AudioEngine::reverbCompressorVolume >= 0); }
};
} // namespace deluge::gui::menu_item::reverb::compressor
2 changes: 1 addition & 1 deletion src/deluge/gui/menu_item/reverb/compressor/volume.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class Volume final : public Integer {
AudioEngine::reverbCompressorVolume = this->getValue() * 21474836;
AudioEngine::mustUpdateReverbParamsBeforeNextRender = true;
}
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
[[nodiscard]] int32_t getMinValue() const override { return -1; }

void drawValue() override {
Expand Down
6 changes: 3 additions & 3 deletions src/deluge/gui/menu_item/reverb/dampening.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ namespace deluge::gui::menu_item::reverb {
class Dampening final : public Integer {
public:
using Integer::Integer;
void readCurrentValue() override { this->setValue(std::round(AudioEngine::reverb.getdamp() * 50)); }
void writeCurrentValue() override { AudioEngine::reverb.setdamp((float)this->getValue() / 50); }
[[nodiscard]] int32_t getMaxValue() const override { return 50; }
void readCurrentValue() override { this->setValue(std::round(AudioEngine::reverb.getdamp() * kMaxMenuValue)); }
void writeCurrentValue() override { AudioEngine::reverb.setdamp((float)this->getValue() / kMaxMenuValue); }
[[nodiscard]] int32_t getMaxValue() const override { return kMaxMenuValue; }
};
} // namespace deluge::gui::menu_item::reverb
Loading