[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[sc-dev] idle



I've added the message idle to SimpleNumber.
This is how it works:

// for 6 seconds, return 200, then continue
	(
	r = Routine {
			199.yield;
			189.yield;
			6.idle(200);
			199.yield;
			189.yield;
	};

	fork {
		loop {
			r.value.postln;
			1.wait;
		}
	}
	);

	// the value can also be a stream or a function
	(
	r = Routine {
			199.yield;
			189.yield;
			6.idle(Routine { 100.do { |i| i.yield } });
			199.yield;
			189.yield;
	};

	fork {
		loop {
			r.value.postln;
			1.wait;
		}
	}
	);


objections / ideas ?
--





.

_______________________________________________
sc-dev mailing list

info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/