BogaudioModules

BogaudioModules for VCV Rack
Log | Files | Refs | README | LICENSE

commit 8b8f99140270f2d921a4c5c54ee779379819f85c
parent db1de25d495caa9f707c51df005a93f1935a0ac8
Author: Matt Demanett <matt@demanett.net>
Date:   Tue, 15 Sep 2020 23:18:24 -0400

LPG and LLPG: tune timings.  Fix output on LLPG.

Diffstat:
Msrc/LLPG.cpp | 7++++---
Msrc/LLPG.hpp | 4++--
Msrc/LPG.cpp | 6+++---
Msrc/LPG.hpp | 4++--
4 files changed, 11 insertions(+), 10 deletions(-)

diff --git a/src/LLPG.cpp b/src/LLPG.cpp @@ -47,11 +47,11 @@ void LLPG::modulateChannel(int c) { _sampleRate, params[RESPONSE_PARAM], NULL, - 300.0f, + 100.0f, params[SHAPE_PARAM], params[RESPONSE_PARAM], NULL, - 1000.0f, + 2000.0f, params[SHAPE_PARAM], c, true @@ -64,6 +64,7 @@ void LLPG::processChannel(const ProcessArgs& args, int c) { if (e.trigger.process(inputs[GATE_INPUT].getPolyVoltage(c))) { float time = clamp(params[RESPONSE_PARAM].getValue(), 0.0f, 1.0f); time *= time; + time *= 0.1f; time += 0.01f; e.gateSeconds = time; @@ -103,7 +104,7 @@ void LLPG::processChannel(const ProcessArgs& args, int c) { e.vca.setLevel(Amplifier::minDecibels * (1.0f - level)); out = e.vca.next(out); outputs[OUT_OUTPUT].setChannels(_channels); - outputs[OUT_OUTPUT].setVoltage(env * 10.0f, c); + outputs[OUT_OUTPUT].setVoltage(out, c); } struct LLPGWidget : BGModuleWidget { diff --git a/src/LLPG.hpp b/src/LLPG.hpp @@ -48,8 +48,8 @@ struct LLPG : BGModule { LLPG() { config(NUM_PARAMS, NUM_INPUTS, NUM_OUTPUTS); - configParam(RESPONSE_PARAM, 0.0f, 1.0f, 0.2f, "Response", "%", 0.0f, 100.0f); - configParam(SHAPE_PARAM, -1.0f, 1.0f, 0.0f, "Shape"); + configParam(RESPONSE_PARAM, 0.0f, 1.0f, 0.5f, "Response", "%", 0.0f, 100.0f); + configParam(SHAPE_PARAM, -1.0f, 1.0f, -0.25f, "Shape"); configParam<ScaledSquaringParamQuantity<(int)maxFilterCutoff>>(LPF_PARAM, 0.0f, 1.0f, 0.0f, "LPF cutoff", " HZ"); configParam(VCA_PARAM, 0.0f, 1.0f, 0.0f, "VCA level", "%", 0.0f, 100.0f); } diff --git a/src/LPG.cpp b/src/LPG.cpp @@ -62,11 +62,11 @@ void LPG::modulateChannel(int c) { _sampleRate, params[RESPONSE_PARAM], &inputs[RESPONSE_INPUT], - 300.0f * _timeScale, + 100.0f * _timeScale, params[RISE_SHAPE_PARAM], params[RESPONSE_PARAM], &inputs[RESPONSE_INPUT], - 1000.0f * _timeScale, + 2000.0f * _timeScale, params[FALL_SHAPE_PARAM], c ); @@ -81,7 +81,7 @@ void LPG::processChannel(const ProcessArgs& args, int c) { time *= clamp(inputs[RESPONSE_INPUT].getPolyVoltage(c) / 10.0f, 0.0f, 1.0f); } time *= time; - time *= _timeScale * 0.5f; + time *= _timeScale * 0.1f; time += 0.01f; e.gateSeconds = time; diff --git a/src/LPG.hpp b/src/LPG.hpp @@ -60,10 +60,10 @@ struct LPG : LPGEnvBaseModule { : LPGEnvBaseModule(-1, LONG_PARAM, 5.0f) { config(NUM_PARAMS, NUM_INPUTS, NUM_OUTPUTS); - configParam(RESPONSE_PARAM, 0.0f, 1.0f, 0.2f, "Response", "%", 0.0f, 100.0f); + configParam(RESPONSE_PARAM, 0.0f, 1.0f, 0.5f, "Response", "%", 0.0f, 100.0f); configParam(LONG_PARAM, 0.0f, 1.0f, 0.0f, "Long mode"); configParam(RISE_SHAPE_PARAM, -1.0f, 1.0f, 0.0f, "Rise shape"); - configParam(FALL_SHAPE_PARAM, -1.0f, 1.0f, 0.0f, "Fall shape"); + configParam(FALL_SHAPE_PARAM, -1.0f, 1.0f, -0.5f, "Fall shape"); configParam(LPF_ENV_PARAM, -1.0f, 1.0f, 0.8f, "LPF envelope amount", "%", 0.0f, 100.0f); configParam<ScaledSquaringParamQuantity<(int)maxFilterCutoff>>(LPF_BIAS_PARAM, 0.0f, 1.0f, 0.0f, "LPF cutoff", " HZ"); configParam(VCA_ENV_PARAM, -1.0f, 1.0f, 1.0f, "VCA envelope amount", "%", 0.0f, 100.0f);