[sc-users] Grains with Individual FFT processes

Dionysis Athinaios adroid28 at yahoo.gr
Thu Feb 21 12:36:29 PST 2008


Hello everyone :)

I am a bit confused about the function of the PV UGens and I wonder whether
someone
can help me. I want to make a SynthDef that is playing a grain that is part
of a granular 
texture. The synth will be iterated by a routine with each grain having
different arguments 
for, let's say as an example, the wipe argument of PV_BrickWall. 
My question is that since I need a new buffer for each grain, where is the
right place to allocate it?

//my synth Def


SynthDef("Grain_PV_BrickWall", { 
arg ratemin = 1, ratemax =1, buf, volmin= 1, volmax= 1, outbus=0, pan=1.0,
conPan = 1.0, 
       spread = 0.0, amp = 1.0, att = 0.05, dec = 0, rel = 0.2, superAtt =
1.0, superDecay = 1.0, 
       wipe = 0, buffer1;

var in, out, chain, env;

in= PlayBuf.ar(1, buf, BufRateScale.kr(buf)*Rand(ratemin, ratemax));

chain = FFT(buffer1, in);

chain = PV_BrickWall(chain, wipe); 

out = Pan2.ar( IFFT(chain), (conPan*Rand(pan - spread, pan +
spread)).fold(-1.0,1.0));
         
env =  EnvGen.ar(Env.new([0, superAtt, superDecay, 0],[att, dec, rel],'sine'
), 1.0,1, doneAction: 2);

SystemClock.sched(att+dec+rel+1, {buffer1.free});

Out.ar(outbus, out*amp*env*Rand(volmin, volmax));

}).load(s);



-- 
View this message in context: http://www.nabble.com/Grains-with-Individual-FFT-processes-tp15618693p15618693.html
Sent from the Supercollider - User mailing list archive at Nabble.com.



More information about the sc-users mailing list