/*
Tito HackPact 8 de Julio 2011
*/

p=ProxySpace.push(s.boot)
~rev={FreeVerb.ar(~out.ar,0.5,0.3467)!2}
~out.stop;~rev.play
s.meter

~dardanoNotas={Demand.ar(~dardanoTrig.ar,0,Drand([0,3,7,4,12].midiratio*30,inf))};
~dardano={SinOsc.ar(~dardanoNotas.ar*2,0,0.95)+RLPF.ar(Pulse.ar(~dardanoNotas.ar,0.5,0.125),6000,0.1)};
~dardanoTrig={Impulse.ar(3)};
~dardanoSilencio={Demand.ar(~dardanoTrig.ar,0,Drand(Array.rand(8,0,1),inf))};
~dardanoDecay={Decay2.ar(~dardanoTrig.ar,0.05,1/3,~dardano.ar)};
~out=~dardanoDecay;

~helespontoNotas={Demand.ar(~helespontoTrig.ar,0,Drand([0,3,7,4,12].midiratio*30*8,inf))};
~helespontoSilencio={Demand.ar(~helespontoTrig.ar,0,Drand(Array.rand(8,0,1),inf))};
~helesponto={(SinOsc.ar(~helespontoNotas.ar,0,0.5)+RLPF.ar(Pulse.ar(~helespontoNotas.ar,0.5,0.5),10000,0.1))*~helespontoSilencio.ar*0.2};
~helespontoTrig={Impulse.ar(3.5)};
~helespontoDecay={Decay2.ar(~helespontoTrig.ar,0.01,0.85,~helesponto.ar)};
~out=~dardanoDecay+~helespontoDecay;

~dardanoTrig={Impulse.ar(3.5)};
~helespontoTrig={Impulse.ar(3.5)};
~helespontoNotas={Demand.ar(~helespontoTrig.ar,0,Dseq([3,0,3,5,7,12,10,8].midiratio*30*8,inf))};
~dardanoNotas={Demand.ar(~dardanoTrig.ar,0,Dseq([0,0,0,0,0,-5,-3,-1].midiratio*60,inf))};

1/3.5;
1/2.2857142857143;
~ritmoAcordes={LFPulse.ar(Demand.ar(Impulse.ar(0.4375),0,Dseq([3.5/2,3.5*2],inf)))};
~acordesDemand={Demand.ar(Impulse.ar(0.4375),0,Dseq([[0,3,7],[-2,5,8]],inf))};
~acordes={Mix(Blip.ar(~acordesDemand.ar.midiratio*120*2,10,1/15))*~ritmoAcordes.ar*LFPulse.kr(3.5/3)};
~out=~dardanoDecay+~helespontoDecay+~acordes;

~out=~dardanoDecay;
~out=~helespontoDecay;
~out=~acordes;
~out=~dardanoDecay+~helespontoDecay;
~out=~helespontoDecay+~acordes;
~out=~dardanoDecay+~acordes;
~out=~dardanoDecay+~helespontoDecay+~acordes;

p.fadeTime=10
~out=0