Kassen wrote:
Here you go; This example should be quite clear and suitable for extending for your own purposes, I think, but if I'm wrong please do shout.
Thanks alot. I feel embarrased that I didn't know about last being available for all ugens. I (believe it or not) did look in the documentation, but for ugens and no last is listed there, however I should have looked at http://chuck.cs.princeton.edu/doc/language/ugen.html I'll have a look at your examples, and modify for my needs.
I'd also like the following to work but it seems like I can extend Step but the result will -for some strange reason- not be a Ugen. I'm not the greatest OOP wizard but I really feel that if I extend Ugen the result should be a Ugen as well. Right now we can extend it but not actually do anything with the result.
Ok, so you're in chuck, I was thinking about going c++... Anyways, I had the impression that defining our own ugens in chuck-code wasn't supported, but I sure hope I was wrong. Obviously this would make the LoFi example sooo smooth: SndBuf s => LoFi l => dac; s.read("something.wav"); 22100 => l.rate; 8 => l.bits; 1::week => now; The second last section on http://chuck.cs.princeton.edu/doc/language/ugen.html says "creating [ugens], comming soon". It seems this (missing) info is exactly what I'm looking for. Could any of the coders fill us in? -- peace, love & harmony Atte http://atte.dk | http://myspace.com/attejensen http://anagrammer.dk | http://modlys.dk