[chuck-users] SndBuf: setting loop

Martin Ahnelöv operagasten at gmail.com
Thu Oct 11 03:40:49 EDT 2007


ons 2007-10-10 klockan 15:52 +0200 skrev Atte André Jensen:
> Hi
> 
> I looked in the manual but couldn't find the answer: Is is possible to 
> set the loop start/end with SndBuf from within chuck? It's not mentioned 
> at http://chuck.cs.princeton.edu/doc/program/ugen_full.html#sndbuf. 
> Alternatively: is there another mechanism to play samples that allows 
> setting the loop start/end?
> 

I think you have to wrap it in a while-statement:

while( true ) {
	0 => buf.pos;
	buf.samples()::samp => now;
}

Though, a .loop(true/false) would be cool.

GSTN



More information about the chuck-users mailing list