-
Pfuncn: Filter: Description Class methods new Inherited class methods Instance methods Inherited instance methods Undocumented instance methods embedInStream func repeats Examples Classes | Streams-Patterns-Events > Patterns'>Patterns > Pat ...
-
Pfuncn function pattern of given length superclass: Pattern Pfunc(func, repeats) Returns a stream that returns values from the func. func - stream function repeats - end after this number of times See also: Pfunc // example ( var a, b, c; a ...
-
... sound); }).store; ) ( Pbind( \instrument, \hasherTest, \dur, 5, \rate, Pfuncn({100.rand}, inf), \freq, Pfuncn({10000.rand}, inf), \index, Pfuncn({20000.rand}, inf), \tRate, Pfuncn({1000.rand}, inf), \fRate, 5, ).play; )
-
... (); ~params[\freq] = Pwhite(440, 880).asStream; Pbind( \type, \algaNote, \freq, Pfuncn({ ~params[\freq].next }, inf);, \dur, 0.05, \amp, 0.01 ).play; ~interp = { | param, what, ft = 1 | var blend = Pseg([0, 1, 1], [ft, inf], \lin); ~params[ ...
-
... \story ++ item).asSymbol] = Pbind( \instrument, \bufRdPan, \bufnum, Pfuncn {c[\story][item].choose}, \amp, 0.4, ); }; }; }; //// FSM for each group p[\storyG1] = Pfsm([ #[0, 2, 4, 5], p[(\story ++ v ...
-
( ~dur = 1; p = Pbind( \degree, Pwhite(0, 7, inf), \dur, Pfuncn({ var a = ~dur.next; a.postln; a }, inf) ).playRescheduling(quant:1) ) p.reschedule(2); p.algaSchedAtQuantOnce(1, { "ye".postln; ~dur = 0.5 }) p.algaSchedOnce(0.1, { "ye".postl ...
-
... s (90, -1, 10), \dur , 0.5).asStream; z = Pseq ([2, 3, 1, 2], 1).asStream; ~a = Pfuncn ({ x.next(()) }, { z.next }); ~b = Pfuncn ({ y.next(()) }, { z.next }); PsymNilSafe ( Pseq ( "ab" , inf )).trace.play; // shorter with method 'symplay': ...
-
... ries(90, -1, 10), \dur, 0.5).asStream; z = Pseq([2, 3, 1, 2], 1).asStream; ~a = Pfuncn({ x.next(()) }, { z.next }); ~b = Pfuncn({ y.next(()) }, { z.next }); PsymNilSafe(Pseq("ab", inf)).trace.play; // shorter with method 'symplay': // trace ...
-
... r x; var func = { "an error happened" .postln }; a = Pprotect ( Pseq ([1, 3, 3, Pfuncn ({ Error .throw }), 2]), func); x = Pbind ( \degree , a, \dur , 0.5).play; )
-
( ~dur = 1; ~stream = Pbind( \dur, Pfuncn( { ~dur.next }, inf), \degree, Pseries(0, 1) % 20 ).asStream; ~condition = Condition(false); ~clock = TempoClock.default; ~routine = Routine({ loop { ~player !? _.stop(); // stop the old one, if the ...