aboutsummaryrefslogtreecommitdiff
path: root/loquelic_vo.dsp
diff options
context:
space:
mode:
authorVee9ahd1 <>2021-05-11 15:29:40 -0400
committerVee9ahd1 <>2021-05-11 15:29:40 -0400
commit194676e190b827c6b12318213261d4e47ec7e6aa (patch)
tree37802291ed88fcc79f5e0946d7a283ca345afb12 /loquelic_vo.dsp
initial commit
Diffstat (limited to 'loquelic_vo.dsp')
-rw-r--r--loquelic_vo.dsp30
1 files changed, 30 insertions, 0 deletions
diff --git a/loquelic_vo.dsp b/loquelic_vo.dsp
new file mode 100644
index 0000000..7687932
--- /dev/null
+++ b/loquelic_vo.dsp
@@ -0,0 +1,30 @@
+import("stdfaust.lib");
+import("src/util.dsp");
+
+UIGroupOscA(x) = hgroup("Oscillator A", x);
+UIFreqA = UIGroupOscA(vslider("Frequency", 440.0, 20.0, 10000.0, 1));
+UIFoldGain = UIGroupOscA(vslider("Fold", 1.0, 0.0, 5.0, 0.01));
+UIMorph = UIGroupOscA(vslider("Morph", 0.5, 0.0, 1.0, 0.001));
+
+UIGroupOscB(x) = hgroup("Oscillator B", x);
+UIFreqB = UIGroupOscB(vslider("Frequency", 440.0, 20.0, 10000.0, 1));
+UIDecay = UIGroupOscB(vslider("Decay", 0.0, 0.0, 1.0, 0.01));
+
+UIMod = vslider("Modulation", 0.0, 0.0, 1.0, 0.001);
+
+process = oscA * oscB
+with {
+ oscB = UIFreqA
+ : phase
+ : *(-UIDecay*10.0)
+ : exp;
+
+ oscA = UIFreqB
+ : phase
+ : +(oscB*UIMod)
+ : fmod(_,1.0)
+ : knee(UIMorph)
+ : sin(_*2.0*ma.PI)
+ : *(UIFoldGain)
+ : fold;
+};