From e6669e7d7ecfd5bd8fe3c2135132e7b74d62f468 Mon Sep 17 00:00:00 2001 From: Eugene Petkevich Date: Mon, 15 Jan 2024 23:00:36 +0100 Subject: [PATCH] livecoding session --- ...\221\320\260\322\231\321\216-patterns.scd" | 266 ++++++++++++++++++ ...322\221\320\260\322\231\321\216-setup.scd" | 58 ++++ 2 files changed, 324 insertions(+) create mode 100644 "\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-patterns.scd" create mode 100644 "\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-setup.scd" diff --git "a/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-patterns.scd" "b/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-patterns.scd" new file mode 100644 index 0000000..a322219 --- /dev/null +++ "b/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-patterns.scd" @@ -0,0 +1,266 @@ +( +SynthDef(\lajyfika, { arg + out=0, + amp=1, + relAmp=1, // for controlling volume of a set of synths + pan=0, + t_trig=1, + gate=1, + freq=440, + freqStart=440, + freqEnd=440,doneAction=2, cut=800, rez=0.8, + modFreq=3, modAmp=0.01, release=1.0 + ; + var sig = 0; + var panDelay = 0.005; + var modFreqMul = SinOsc.kr(modFreq, 0, modAmp, 1); + var curFreq = EnvGen.ar(Env([freqStart, freq, freqEnd], [0.01, release], \exp, 1), gate); + sig = sig + Pulse.ar(curFreq * modFreqMul); + //sig = (sig*11.2).fold(-1, 1); + sig = RLPF.ar(sig, cut, rez); + sig = sig * EnvGen.ar(Env.asr(releaseTime: release), gate, doneAction: doneAction); + sig = Pan2.ar(sig, pan); + sig = [DelayN.ar(sig[0], panDelay, (panDelay*pan).clip(0, 1)), DelayN.ar(sig[1], panDelay, (panDelay.neg*pan).clip(0, 1))]; + Out.ar(out, sig * amp * relAmp); +}).add; +) + +// tempo and meter + +( +TempoClock.tempo = 1.5; +TempoClock.schedAbs(TempoClock.nextBar, { TempoClock.beatsPerBar_(4) }); +) + +// pdefs + +// bass + +( +~walomaju = 4.split(3)++4.split(4)++4.split(2)++4.split(1); +"~walomaju = %\n".postf(~walomaju); +) + +Pdefn(\wigipoto, Pseq(~walomaju, inf)).quant_(TempoClock.beatsPerBar); + +( +Pdef(\helagijo, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 40, + pan: 0, + trig: 1, + dur: Pdefn(\wigipoto), + legato: Pn(Pseries(0.2, 0.1, ~walomaju.size), inf), + release: TempoClock.tempo.reciprocal * 5, + octave: 3, + note: Pshuf([0, 2, 2, 5, 5, 5, 7, 7, 3], inf), + freqStart: Pkey(\freq) / 4, + freqEnd: Pkey(\freq) / 3, + modFreq: 18, + modAmp: 0.007, + cut: Pkey(\freq)*3, + rez: 0.9, +])).quant_(TempoClock.beatsPerBar*4); +) + +Pdefn(\wigipoto).swap(\fbs); + +Pdef(\helagijo).play; +Pdef(\helagijo).stop; + +// bass 2 + +( +~qilyxere = 4.split(3)++4.split(4)++4.split(2)++4.split(1); +"~qilyxere = %\n".postf(~qilyxere); +) + +Pdefn(\qilyxere, Pseq(~qilyxere, inf)).quant_(TempoClock.beatsPerBar); + +( +Pdef(\hitiliko, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 36, + pan: 0, + trig: 1, + dur: Pdefn(\qilyxere), + legato: Pn(Pseries(0.2, 0.01, ~qilyxere.size), inf), + release: TempoClock.tempo.reciprocal * 20, + octave: Pseq([2, 3, 2, 3, 4, 5], inf), + note: Pshuf([0, 2, 2, 5, 7, 7, 7, 7, 4], inf), + freqStart: Pkey(\freq) * 2, + freqEnd: Pkey(\freq) * 1.5, + modFreq: 3.1, + modAmp: 0.02, + cut: Pkey(\freq)*5, + rez: 0.9, +])).quant_(TempoClock.beatsPerBar*4); +) + +Pdefn(\qilyxere).swap(\fbs); + +Pdef(\hitiliko).play; + +// melody 1 + +( +~nydutike = 2.split(3)++1.split(2)++1.split(2); +~nydutike = ~nydutike ++ ~nydutike ++ ([3, 3, 4, 2, 2, 1, 1] / 2); +"~nydutike = %\n".postf(~nydutike); +) + +Pdefn(\nydutike, Pseq(~nydutike, inf)).quant_(TempoClock.beatsPerBar); + +( +Pdef(\wizopebe, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 25, + pan: [-0.5, 0.5], + trig: 1, + dur: Pdefn(\nydutike), + legato: Pwhite(0.2, 0.4), + release: TempoClock.tempo.reciprocal * 40, + octave: Prand([5, 6], inf), + note: Pshuf([0, 2, 3, 5, 7, 9, 7, 7, 5, 7, 5, 3, 2, 0], inf), + freqStart: Pkey(\freq) * 4, + freqEnd: Pkey(\freq) / 2, + modFreq: [14, 14.4], + modAmp: [0.0007, 0.0071], + cut: Pkey(\freq)*Pwhite(4, 6, inf), + rez: [0.9, 0.8], +])).quant_(TempoClock.beatsPerBar); +) + +Pdefn(\nydutike).swap(\fbs); +Pdefn(\nydutike).swap; + +Pdef(\wizopebe).play; + +// melody 2 + +( +Pdef(\cowacati, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 30, + pan: [-0.7, 0.7], + trig: 1, + dur: Pdefn(\nydutike), + legato: Pwhite(0.4, 0.6), + release: TempoClock.tempo.reciprocal * 40, + octave: Prand([3, 4], inf), + note: Pshuf([0, 2, 3, 5, 7, 9, 7, 7, 5, 7, 5, 3, 2, 0], inf), + freqStart: Pkey(\freq) * 2, + freqEnd: Pkey(\freq) * 2, + modFreq: [4.4, 4], + modAmp: [0.0071, 0.013], + cut: Pkey(\freq)*Pwhite(2, 4, inf), + rez: [0.6, 0.7], + detune: 1, + timeOffset: 0, +])).quant_(TempoClock.beatsPerBar); +) + +Pdef(\cowacati).play; + +// melody 3 + +~modFreqX = ~makeControlMouseX.(0.5, 15, \exp); +~modAmpY = ~makeControlMouseY.(0.01, 0.2, \exp); + +( +Pdef(\cicyxezy, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 25, + pan: Pwhite(0.2, 0.8, inf) * [-1, 1], + trig: 1, + dur: Pseq([3, 2, 3].split(2)/2, inf), + legato: Pwhite(0.1, 0.5), + release: TempoClock.tempo.reciprocal * 1, + octave: Prand([8], inf), + note: Pseq([0, 7, 3, 5, 7, 5], inf), + freqStart: Pkey(\freq) / Pwhite(1.0, 2.0), + freqEnd: Pkey(\freq) * Pwhite(1.0, 2.0), + modFreq: ~modFreqX, + modAmp: ~modAmpY, + cut: ~cutX, + rez: [0.6, 0.7], +])).quant_(TempoClock.beatsPerBar*1); +) + +Pdef(\cicyxezy).stop; + +// melody 4 + +~cut2X = ~makeControlMouseX.(800, 12000, \exp); +~cut2Y = ~makeControlMouseY.(0.1, 20, \exp); + +( +Pdef(\xafywima, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 30, + pan: Pwhite(0.2, 0.8, inf) * [-1, 1], + trig: 1, + dur: Pseq([3, 3, 4, 2, 2, 1, 1]/2, inf), + legato: Pwhite(0.2, 0.3), + release: TempoClock.tempo.reciprocal * 4, + octave: Prand([7], inf), + note: Pseq([0, 7, 3, 5, 7, 5], inf), + freqStart: Pkey(\freq) * 1, + freqEnd: Pkey(\freq) * 1, + modFreq: ~cutY, + modAmp: Pwhite(0.0001, 0.01, inf), + cut: ~cutX, + rez: [0.6, 0.7], +])).quant_(TempoClock.beatsPerBar*2); +) + +Pdef(\xafywima).stop; + +// beat + +( +~lunewite = 4.split(3); +"~walomaju = %\n".postf(~lunewite); +) + +( +Pdefn(\lunewite, Pwrand([ + Pseq(~lunewite, 1), + Pseq(1!4, 1), +], [0, 10], inf)).quant_(TempoClock.beatsPerBar); +) + +( +Pdef(\sijytufy, Pbind(*[ + group: ~helagijoGroup, + out: ~mainBus, + instrument: \lajyfika, + db: 55, + pan: 0, + dur: Pdefn(\lunewite), + legato: 0.2, + release: TempoClock.tempo.reciprocal / 1, + octave: 2, + note: 3, + freqStart: Pkey(\freq) / 4, + freqEnd: Pkey(\freq) * 2, + modFreq: 2, + modAmp: 0.01, + cut: Pkey(\freq)*2, + rez: 0.9, +])).quant_(TempoClock.beatsPerBar*4); +) + +Pdef(\sijytufy).stop; \ No newline at end of file diff --git "a/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-setup.scd" "b/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-setup.scd" new file mode 100644 index 0000000..9179f08 --- /dev/null +++ "b/\320\232\320\260/\320\232\320\260\320\274\321\217\321\206 35.4.7.7 2024-01-14 \342\213\206 \320\216\321\215\322\221\320\260\322\231\321\216 \342\213\206 livecoding/\320\216\321\215\322\221\320\260\322\231\321\216-setup.scd" @@ -0,0 +1,58 @@ +// history + +History.clear.end; +History.start; + +// init + +( +~createGroupsBusses = { + ~instrumentGroup = Group(s); + ~effectGroup = Group.after(~instrumentGroup); + ~masterGroup = Group.after(~effectGroup); + + ~helagijoGroup = Group.tail(~instrumentGroup); + + ~mainBus = Bus.audio(s, 2); + ~masterer = Synth(\masterer, ( + in: ~mainBus, + out: a.h, + amp: -60.dbamp, + lookAheadTime: 0.05, + ).asPairs, ~masterGroup); +}; +ServerTree.removeAll; +ServerTree.add(~createGroupsBusses); + +~drawWindows = { + s.plotTree +}; +ServerBoot.removeAll; +//ServerBoot.add(~drawWindows); +) + +// server boot + +s.reboot; + +// recording + +( +s.recorder.filePrefix = "Ўэґаҙю_main_"; +s.record(bus: ~mainBus); + +~r = Recorder(s); +~r.filePrefix = "Ўэґаҙю_master_"; +~r.record(bus: a.h); +) + +( +s.stopRecording; +~r.stopRecording; +) + +// finishing + +History.end; +History.saveCS(PathName(thisProcess.nowExecutingPath).parentPath+/+"history-cs.scd"); +History.saveStory(PathName(thisProcess.nowExecutingPath).parentPath+/+"history-story.scd"); \ No newline at end of file -- 2.17.1