Add another sandbox file
authorEugene Petkevich <nasedil.genio.code@gmail.com>
Thu, 12 May 2022 18:42:12 +0000 (21:42 +0300)
committerEugene Petkevich <nasedil.genio.code@gmail.com>
Thu, 12 May 2022 18:42:12 +0000 (21:42 +0300)
33.7.3.2-с-Нэцэ.scd [new file with mode: 0644]

diff --git a/33.7.3.2-с-Нэцэ.scd b/33.7.3.2-с-Нэцэ.scd
new file mode 100644 (file)
index 0000000..27a82ad
--- /dev/null
@@ -0,0 +1,54 @@
+(
+Pdef(\daki, ~se.makeSynthBind <> Pbind(
+  \dur, Pwrand([
+    Pseq(1!4, 1),
+    Pseq(2!2, 1),
+    Pseq((4/3)!3, 1),
+  ], [5, 2, 1].normalizeSum, inf),
+  \octave, [4, 5],
+  \note, Pxrand([0, 4, 9, 7, 2.5], inf),
+  \db, -5,
+)).quant_(4).stop;
+)
+
+(
+Pdef(\niru, ~se.makeSynthBind <> Pbind(
+  \dur, 1/2 * Pwrand([
+    Pseq(1!4, 1),
+    Pseq(2!2, 1),
+    Pseq((4/3)!3, 1),
+  ], [5, 2, 1].normalizeSum, inf),
+  \octave, [2, 3],
+  \note, Pxrand([0, 4, 9, 7], inf),
+  \db, -10,
+)).quant_(4).stop;
+)
+
+(
+Pdef(\bagi, Pbind(
+  \instrument, \dire,
+  \dur, 1/4 * Pwrand([
+    Pseq(1!4, 1),
+    Pseq(2!2, 1),
+    Pseq((4/3)!3, 1),
+  ], [5, 2, 1].normalizeSum, inf),
+  \octave, [2, 3],
+  \note, Pxrand([0, 4, 9, 7], inf),
+  \db, -20,
+  \legato, 2,
+)).quant_(4).stop;
+)
+
+TempoClock.tempo = 140 / 60;
+
+(
+SynthDef(\dire, { |amp=1, out=0, freq=440, gate=1|
+  var sig, modFreq, env;
+  modFreq = SinOsc.ar(3000, mul: freq/4, add: freq);
+  sig = Pulse.ar(modFreq);
+  env = EnvGen.ar(Env.adsr(), gate, doneAction: 2);
+  sig = sig * env;
+  sig = Pan2.ar(sig, Rand(-0.5, 0.5));
+  Out.ar(out, sig * amp);
+}).add;
+)
\ No newline at end of file