diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a08832f..dd48f0b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ - Added velocity mode to MIDI-Trig - Added MIDI multiplexing so multiple MIDI modules can use the same MIDI device on Windows - Make Module Browser layout more compact +- Add power meter +- Add icons to toolbar - [VCV Bridge](https://vcvrack.com/manual/Bridge.html) 0.6.1 - Replaced VST effect plugin with VST instrument plugin with audio inputs - Added MIDI support diff --git a/src/Core/QuadMIDIToCVInterface.cpp b/src/Core/QuadMIDIToCVInterface.cpp index 594e84ef..485d3132 100644 --- a/src/Core/QuadMIDIToCVInterface.cpp +++ b/src/Core/QuadMIDIToCVInterface.cpp @@ -27,15 +27,13 @@ struct QuadMIDIToCVInterface : Module { enum PolyMode { ROTATE_MODE, - // Added REUSE option that reuses a channel when receiving the same note. - // Good when using sustain pedal so it doesn't "stack" unisons ... not sure this is the best name but it is descriptive... REUSE_MODE, RESET_MODE, REASSIGN_MODE, UNISON_MODE, NUM_MODES }; - PolyMode polyMode = ROTATE_MODE; + PolyMode polyMode = RESET_MODE; struct NoteData { uint8_t velocity = 0; @@ -351,19 +349,19 @@ struct QuadMIDIToCVInterfaceWidget : ModuleWidget { menu->addChild(MenuEntry::create()); menu->addChild(MenuLabel::create("Polyphony mode")); - std::vector polyModeNames = { - "Rotate", - "Reuse", - "Reset", - "Reassign", - "Unison" - }; - for (int i = 0; i < QuadMIDIToCVInterface::NUM_MODES; i++) { - PolyphonyItem *item = MenuItem::create(polyModeNames[i], CHECKMARK(module->polyMode == i)); + + auto addPolyphonyItem = [&](QuadMIDIToCVInterface::PolyMode polyMode, std::string name) { + PolyphonyItem *item = MenuItem::create(name, CHECKMARK(module->polyMode == polyMode)); item->module = module; - item->polyMode = (QuadMIDIToCVInterface::PolyMode) i; + item->polyMode = polyMode; menu->addChild(item); - } + }; + + addPolyphonyItem(QuadMIDIToCVInterface::RESET_MODE, "Reset"); + addPolyphonyItem(QuadMIDIToCVInterface::ROTATE_MODE, "Rotate"); + addPolyphonyItem(QuadMIDIToCVInterface::REUSE_MODE, "Reuse"); + addPolyphonyItem(QuadMIDIToCVInterface::REASSIGN_MODE, "Reassign"); + addPolyphonyItem(QuadMIDIToCVInterface::UNISON_MODE, "Unison"); } }; diff --git a/src/app/SVGSlider.cpp b/src/app/SVGSlider.cpp index 8931fa4b..63de79f8 100644 --- a/src/app/SVGSlider.cpp +++ b/src/app/SVGSlider.cpp @@ -10,6 +10,8 @@ SVGSlider::SVGSlider() { handle = new SVGWidget(); addChild(handle); + + speed = 2.0; } void SVGSlider::setSVGs(std::shared_ptr backgroundSVG, std::shared_ptr handleSVG) { diff --git a/src/engine.cpp b/src/engine.cpp index 2b1594d3..e383a433 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -97,7 +97,7 @@ static void engineStep() { auto stopTime = std::chrono::high_resolution_clock::now(); float cpuTime = std::chrono::duration(stopTime - startTime).count() * sampleRate; - module->cpuTime += (cpuTime - module->cpuTime) * sampleTime / 0.25f; + module->cpuTime += (cpuTime - module->cpuTime) * sampleTime / 0.5f; } else { module->step();