mirror of
https://codeberg.org/armin/wavetable.git
synced 2026-09-01 14:00:47 +02:00
Add retrigger to step lfo
This commit is contained in:
parent
e698e29a59
commit
4dd62bf66f
7 changed files with 10 additions and 6 deletions
|
|
@ -4,7 +4,7 @@ cmake_minimum_required (VERSION 3.24.0 FATAL_ERROR)
|
||||||
# Set for each plugin
|
# Set for each plugin
|
||||||
#
|
#
|
||||||
set (PLUGIN_NAME Wavetable)
|
set (PLUGIN_NAME Wavetable)
|
||||||
set (PLUGIN_VERSION 1.0.2)
|
set (PLUGIN_VERSION 1.0.3)
|
||||||
set (BUNDLE_ID com.socalabs.wavetable)
|
set (BUNDLE_ID com.socalabs.wavetable)
|
||||||
set (AU_ID WavetableAU)
|
set (AU_ID WavetableAU)
|
||||||
set (LV2_URI "https://socalabs.com/wavetable/")
|
set (LV2_URI "https://socalabs.com/wavetable/")
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit 69cbdc6741e3a9efa1988407a3b4e5dcdf6aa1c4
|
Subproject commit 850d96f45d0b5c006ffc7b36c364c6eae69ce00e
|
||||||
|
|
@ -71,7 +71,8 @@
|
||||||
[
|
[
|
||||||
{ "id": "step", "x": 0, "y": 23, "r": "parW()", "h": 83 },
|
{ "id": "step", "x": 0, "y": 23, "r": "parW()", "h": 83 },
|
||||||
{ "id": "Beat", "x": 67, "y": 106, "w": 42, "h": 57 },
|
{ "id": "Beat", "x": 67, "y": 106, "w": 42, "h": 57 },
|
||||||
{ "id": "Length", "x": "prevR()", "y": "prevY()", "w": 42, "h": 57 }
|
{ "id": "Length", "x": "prevR()", "y": "prevY()", "w": 42, "h": 57 },
|
||||||
|
{ "id": "Retrig", "r": "getR('step') - 3", "y": "getY('step') + 3", "w": 12, "h": 12 }
|
||||||
] },
|
] },
|
||||||
{ "id": "mod", "x": "prevR()+1", "y": "prevY()", "r": "parW()", "h": 163, "children":
|
{ "id": "mod", "x": "prevR()+1", "y": "prevY()", "r": "parW()", "h": 163, "children":
|
||||||
[
|
[
|
||||||
|
|
|
||||||
|
|
@ -407,6 +407,8 @@ public:
|
||||||
g->setParams (prs.beat, prs.length, prs.level, prs.enable);
|
g->setParams (prs.beat, prs.length, prs.level, prs.enable);
|
||||||
addControl (g, 0, 0, 4, 1);
|
addControl (g, 0, 0, 4, 1);
|
||||||
|
|
||||||
|
addControl (new gin::SVGPluginButton (prs.retrig, gin::Assets::retrigger));
|
||||||
|
|
||||||
setSize (112, 163);
|
setSize (112, 163);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -232,7 +232,8 @@ void WavetableAudioProcessor::StepLFOParams::setup (WavetableAudioProcessor& p)
|
||||||
|
|
||||||
enable = p.addIntParam (id + "enable", nm + "Enable", "Enable", "", { 0.0, 1.0, 1.0, 1.0 }, 0.0f, 0.0f, enableTextFunction);
|
enable = p.addIntParam (id + "enable", nm + "Enable", "Enable", "", { 0.0, 1.0, 1.0, 1.0 }, 0.0f, 0.0f, enableTextFunction);
|
||||||
beat = p.addIntParam (id + "beat", nm + "Beat", "Beat", "", { 0.0, float (notes.size() - 1), 1.0, 1.0 }, 13.0, 0.0f, durationTextFunction);
|
beat = p.addIntParam (id + "beat", nm + "Beat", "Beat", "", { 0.0, float (notes.size() - 1), 1.0, 1.0 }, 13.0, 0.0f, durationTextFunction);
|
||||||
length = p.addIntParam (id + "length", nm + "Length", "Length", "", { 2.0, 32.0, 1.0, 1.0f }, 8.0f, 0.0f);
|
length = p.addIntParam (id + "length", nm + "Length", "Length", "", { 2.0, 32.0, 1.0, 1.0f }, 8.0f, 0.0f);
|
||||||
|
retrig = p.addIntParam (id + "retrig", nm + "Retrig", "Retrig", "", { 0.0, 1.0, 1.0, 1.0 }, 1.0, 0.0f, enableTextFunction);
|
||||||
|
|
||||||
for (int i = 0; i < Cfg::numStepLFOSteps; i++)
|
for (int i = 0; i < Cfg::numStepLFOSteps; i++)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -119,7 +119,7 @@ public:
|
||||||
{
|
{
|
||||||
StepLFOParams() = default;
|
StepLFOParams() = default;
|
||||||
|
|
||||||
gin::Parameter::Ptr enable, beat, length;
|
gin::Parameter::Ptr enable, beat, length, retrig;
|
||||||
gin::Parameter::Ptr level[Cfg::numStepLFOSteps] = { nullptr };
|
gin::Parameter::Ptr level[Cfg::numStepLFOSteps] = { nullptr };
|
||||||
|
|
||||||
void setup (WavetableAudioProcessor& p);
|
void setup (WavetableAudioProcessor& p);
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ void WavetableVoice::noteStarted()
|
||||||
l.noteOn (proc.lfoParams[idx++].retrig->getBoolValue() ? -1 : rng.nextFloat());
|
l.noteOn (proc.lfoParams[idx++].retrig->getBoolValue() ? -1 : rng.nextFloat());
|
||||||
|
|
||||||
modStepLFO.reset();
|
modStepLFO.reset();
|
||||||
modStepLFO.noteOn();
|
modStepLFO.noteOn (proc.stepLfoParams.retrig->getBoolValue() ? -1 : rng.nextFloat());
|
||||||
|
|
||||||
adsr.reset();
|
adsr.reset();
|
||||||
adsr.noteOn();
|
adsr.noteOn();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue