«Cookiemonster» by bernhard
on 31 Mar'20 12:53 inGrainsynth Sampler based on the Example in the Documentation. I'd call it crumblesynthesis. "ME WANT COOKIE!!!"
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
/// Grainsynth Sampler based on the Example in the Documentation. I'd call it crumblesynthesis. /// CLOCK and DURATIOM randomized via LFNoise1, borders are set with mulclock, addclock, muldur and adddur. LFNoise1 folds to positiv with .abs, offset is added after. lfo1 and lfo2 are the speeds of LFNoise1. /// For more silent parts approach addclock to zero or make it negativ /// Env is randomized with PinkNoise /// MouseX is playbackrate, MouseY is position in buffer. Blured with PinkNoise, intensity via vrate and vpos /// Buffers can be switched on the fly with x.set(\buf... /// For Multichannel expansion get rid of Splay.ar and adapt !8 /// use mono cookies, "ME WANT COOKIE!!!" ( SynthDef(\cookiemonster, { arg gate = 1, lfo1 = 0.3, lfo2 = 0.7, vrate = 0.01, vpos = 0.003, mulclock = 64, addclock = 43, muldur = 1, adddur = 0.1, buf=0, amp = 0.1, out=0; var rate, pos, sig, trig, env, atk, rel, dur; trig=Impulse.kr(LFNoise1.kr(lfo1,mulclock).abs+addclock); dur=LFNoise1.kr(lfo2,muldur).abs+adddur; rate=MouseX.kr(0, 5)*PinkNoise.kr(vrate,1); pos=MouseY.kr(0,1)*PinkNoise.kr(vpos,1); atk=dur*PinkNoise.kr(0.9,0.5); rel=dur-atk; env=EnvGen.kr(Env([0, 1, 0], [atk, rel], \sin, 1), gate,1,doneAction: 2); sig={BufGrain.ar(trig,dur,buf,rate,pos,4,env)}!8; sig=Splay.ar(sig); sig=LeakDC.ar(sig*amp); Out.ar(out,sig.tanh); }).add; ) ( x=Synth( \cookiemonster, [\buf, Buffer.read(s,"/Path/to/my/cookiebox/cookie1.wav"), ]);) x.set(\out,0) x.set(\amp,0.1) x.set(\mulclock,12) x.set(\addclock,7) x.set(\lfo1,1.12) x.set(\vrate,0.4) x.set(\muldur,0.1) x.set(\adddur,0.05) x.set(\lfo2,0.24) x.set(\vpos,0.4) x.set(\buf, Buffer.read(s,"/Path/to/my/cookiebox/cookie2.wav")) x.set(\buf, Buffer.read(s,"/Path/to/my/cookiebox/cookie3.wav")) x.set(\buf, Buffer.read(s,"/Path/to/my/cookiebox/cookie4.wav")) x.set(\buf, Buffer.read(s,"/Path/to/my/cookiebox/cookie5.wav")) x.free
reception
This version is flawed . Randomization happens outside the iterated function. Iterations are all the same. Check version 1.1 which more organic