percOrc5




(


var sounds;


Instr.loadAll;


sounds = Instr.leaves('percOrc5');


Sheet({ arg f;

var p;

sounds.do({ |instr|

ActionButton(f.startRow,instr.name,{

if(p.isPlaying,{ p.stop });

p = Patch( instr, [ BeatClockPlayer(8) ] );

p.play;

},minWidth: 300)

})

})


)




(

var sounds,deltas;


Instr.loadAll;


sounds = Instr.leaves('percOrc5');

deltas = Instr.selectBySpec(\deltaStream);


Sheet({ arg f;

var sound, delta;

delta = deltas.first;

sound = sounds.first;


SelectButtonSet(SCVLayoutView.new(f,300@100)

,sounds.collect({ |ins| ins.name.asString }),

{ |i| sound = sounds[i]; },width: 400);


SelectButtonSet(SCVLayoutView.new(f,300@100)

,deltas.collect({ |ins| ins.name.asString }),

{ |i| delta = deltas[i]; },width: 400);


ActionButton(f,"MAKE PATCH...",{

var p, deltaPatternMaker, trig;


deltaPatternMaker = Patch( delta ).rand;

trig = Stream2Trig(1.0, deltaPatternMaker.value );


p = Patch( sound, [ trig ] ).rand;

p.gui

},minWidth: 300);

},"Select sound and rhythm", 1600@600)


)