diff --git a/docs/community_features.md b/docs/community_features.md index 07946d3342..874a6a9fd2 100644 --- a/docs/community_features.md +++ b/docs/community_features.md @@ -211,6 +211,7 @@ Synchronization modes accessible through the "LFO SYNC" shortcut. - ([#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). + - ([#658]) Added Stutter Rate Parameter to Automation View. There is no grid shortcut for this parameter so you will not see a pad on the Automation Overview that indicates whether Stutter has been automated. This parameter can be selected and automated using the Select Encoder to scroll the available list of Automatable Parameters. #### 4.3.6 - Set Probability By Row @@ -406,4 +407,5 @@ This list includes all preprocessor switches that can alter firmware behaviour a [#630]: https://github.com/SynthstromAudible/DelugeFirmware/pull/630 [#636]: https://github.com/SynthstromAudible/DelugeFirmware/pull/636 [#653]: https://github.com/SynthstromAudible/DelugeFirmware/pull/653 +[#658]: https://github.com/SynthstromAudible/DelugeFirmware/pull/658 [Automation View Documentation]: https://github.com/SynthstromAudible/DelugeFirmware/blob/release/1.0/docs/features/automation_view.md diff --git a/docs/features/automation_view.md b/docs/features/automation_view.md index daa0ccf4d5..df23fdc174 100644 --- a/docs/features/automation_view.md +++ b/docs/features/automation_view.md @@ -6,7 +6,7 @@ Automatable Parameters are broken down into two categories for Automation Instru 1. Automatable Parameters for Synths, Kits with affect entire DISABLED, and Midi ->The 55 parameters that can be edited are: +>The 56 parameters that can be edited are: > > - **Master** Level, Pitch, Pan > - **LPF** Frequency, Resonance, Morph @@ -28,10 +28,11 @@ Automatable Parameters are broken down into two categories for Automation Instru > - **Arp** Rate, Gate > - **Noise** Level > - **Portamento** +> - **Stutter** Rate 2. Automatable Parameters for Kits with affect entire ENABLED ->The 24 parameters that can be edited are: +>The 25 parameters that can be edited are: > > - **Master** Level, Pitch, Pan > - **LPF** Frequency, Resonance @@ -44,6 +45,7 @@ Automatable Parameters are broken down into two categories for Automation Instru > - **Mod FX** Offset, Feedback, Depth, Rate > - **Arp** Gate > - **Portamento** +> - **Stutter** Rate It can be thought of as a layer sitting on top of the Instrument Clip View for Synths, Kits and Midi instrument clip types. This PR does not address automation for audio clips. diff --git a/src/definitions_cxx.hpp b/src/definitions_cxx.hpp index f1046d65de..59940c4ac6 100644 --- a/src/definitions_cxx.hpp +++ b/src/definitions_cxx.hpp @@ -374,8 +374,8 @@ constexpr int32_t kMinMenuPatchCableValue = -1 * kMaxMenuPatchCableValue; //Automation View constants constexpr int32_t kNoSelection = 255; -constexpr int32_t kNumNonKitAffectEntireParamsForAutomation = 55; -constexpr int32_t kNumKitAffectEntireParamsForAutomation = 24; +constexpr int32_t kNumNonKitAffectEntireParamsForAutomation = 56; +constexpr int32_t kNumKitAffectEntireParamsForAutomation = 25; constexpr int32_t kLastMidiCCForAutomation = 121; constexpr int32_t kKnobPosOffset = 64; constexpr int32_t kMaxKnobPos = 128; diff --git a/src/deluge/gui/l10n/english.cpp b/src/deluge/gui/l10n/english.cpp index 52bf6cd04a..9d2ebb311f 100644 --- a/src/deluge/gui/l10n/english.cpp +++ b/src/deluge/gui/l10n/english.cpp @@ -187,6 +187,9 @@ PLACE_SDRAM_DATA Language english{ //Portamento {STRING_FOR_PORTAMENTO, "PORTAMENTO"}, + //Stutter Rate + {STRING_FOR_STUTTER_RATE, "Stutter Rate"}, + /* * End Parameter Strings */ diff --git a/src/deluge/gui/l10n/strings.h b/src/deluge/gui/l10n/strings.h index 0c1e787f0d..21c1e33fad 100644 --- a/src/deluge/gui/l10n/strings.h +++ b/src/deluge/gui/l10n/strings.h @@ -569,6 +569,7 @@ enum class String : size_t { STRING_FOR_SOUND, STRING_FOR_AUDIO_CLIP, STRING_FOR_SETTINGS, + STRING_FOR_STUTTER_RATE, // MENU TITLES STRING_FOR_ENV_ATTACK_MENU_TITLE, diff --git a/src/deluge/gui/views/automation_instrument_clip_view.cpp b/src/deluge/gui/views/automation_instrument_clip_view.cpp index 62d60b2700..87c4ccad97 100644 --- a/src/deluge/gui/views/automation_instrument_clip_view.cpp +++ b/src/deluge/gui/views/automation_instrument_clip_view.cpp @@ -166,6 +166,7 @@ const std::array, kNumNonKitAffectEntireParams {Param::Kind::UNPATCHED, Param::Unpatched::Sound::ARP_GATE}, {Param::Kind::PATCHED, Param::Local::NOISE_VOLUME}, //Noise {Param::Kind::UNPATCHED, Param::Unpatched::Sound::PORTAMENTO}, //Portamento + {Param::Kind::UNPATCHED, Param::Unpatched::STUTTER_RATE}, //Stutter Rate }}; //kit affect entire FX - sorted in the order that Parameters are scrolled through on the display @@ -195,6 +196,7 @@ const std::array, kNumKitAffectEntireParamsFor {Param::Kind::GLOBAL_EFFECTABLE, Param::Unpatched::GlobalEffectable::MOD_FX_RATE}, {Param::Kind::UNPATCHED, Param::Unpatched::Sound::ARP_GATE}, //Arp Gate {Param::Kind::UNPATCHED, Param::Unpatched::Sound::PORTAMENTO}, //Portamento + {Param::Kind::UNPATCHED, Param::Unpatched::STUTTER_RATE}, //Stutter Rate }}; //grid sized arrays to assign automatable parameters to the grid @@ -2801,19 +2803,26 @@ void AutomationInstrumentClipView::selectEncoderAction(int8_t offset) { } } - for (int32_t x = 0; x < kDisplayWidth; x++) { - for (int32_t y = 0; y < kDisplayHeight; y++) { + //no shortcut to flash for Stutter, so no need to search for the Shortcut X,Y + //just update name on display, the LED mod indicators, and the grid + if (clip->lastSelectedParamID == Param::Unpatched::STUTTER_RATE) { + goto flashShortcut; + } + else { + for (int32_t x = 0; x < kDisplayWidth; x++) { + for (int32_t y = 0; y < kDisplayHeight; y++) { - if ((clip->lastSelectedParamKind == Param::Kind::PATCHED - && patchedParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID) - || (clip->lastSelectedParamKind == Param::Kind::UNPATCHED - && unpatchedParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID) - || (clip->lastSelectedParamKind == Param::Kind::GLOBAL_EFFECTABLE - && globalEffectableParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID)) { - clip->lastSelectedParamShortcutX = x; - clip->lastSelectedParamShortcutY = y; + if ((clip->lastSelectedParamKind == Param::Kind::PATCHED + && patchedParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID) + || (clip->lastSelectedParamKind == Param::Kind::UNPATCHED + && unpatchedParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID) + || (clip->lastSelectedParamKind == Param::Kind::GLOBAL_EFFECTABLE + && globalEffectableParamShortcutsForAutomation[x][y] == clip->lastSelectedParamID)) { + clip->lastSelectedParamShortcutX = x; + clip->lastSelectedParamShortcutY = y; - goto flashShortcut; + goto flashShortcut; + } } } } diff --git a/src/deluge/util/functions.cpp b/src/deluge/util/functions.cpp index 0bb25b37cd..e40d36a613 100644 --- a/src/deluge/util/functions.cpp +++ b/src/deluge/util/functions.cpp @@ -547,6 +547,10 @@ char const* getUnpatchedParamDisplayName(int32_t p) { case Param::Unpatched::Sound::PORTAMENTO: return l10n::get(STRING_FOR_PORTAMENTO); + //Stutter + case Param::Unpatched::STUTTER_RATE: + return l10n::get(STRING_FOR_STUTTER_RATE); + default: return l10n::get(STRING_FOR_NONE); }