Skip to content

Commit

Permalink
Added Stutter Rate to Automation View (#658)
Browse files Browse the repository at this point in the history
* Added Stutter Rate to Automation View

Stutter Rate parameter can be accessed using the select encoder. It was added as the last parameter in the select encoder list. So you can access it by scrolling select 1 left of Master Volume.

* Updated documentation

* dbt format
  • Loading branch information
seangoodvibes authored Nov 3, 2023
1 parent 17bb21d commit 8e254d3
Show file tree
Hide file tree
Showing 7 changed files with 36 additions and 15 deletions.
2 changes: 2 additions & 0 deletions docs/community_features.md
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down Expand Up @@ -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
6 changes: 4 additions & 2 deletions docs/features/automation_view.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand All @@ -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.

Expand Down
4 changes: 2 additions & 2 deletions src/definitions_cxx.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down
3 changes: 3 additions & 0 deletions src/deluge/gui/l10n/english.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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
*/
Expand Down
1 change: 1 addition & 0 deletions src/deluge/gui/l10n/strings.h
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
31 changes: 20 additions & 11 deletions src/deluge/gui/views/automation_instrument_clip_view.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ const std::array<std::pair<Param::Kind, ParamType>, 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
Expand Down Expand Up @@ -195,6 +196,7 @@ const std::array<std::pair<Param::Kind, ParamType>, 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
Expand Down Expand Up @@ -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;
}
}
}
}
Expand Down
4 changes: 4 additions & 0 deletions src/deluge/util/functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}
Expand Down

0 comments on commit 8e254d3

Please sign in to comment.