[chuck-users] Feature Request/Clarification?

Adam Tindale adamtindale at hotmail.com
Mon Sep 3 15:20:44 EDT 2007


I am a little confused about the me.args() functions that are available.
  It appears that you can pass arguments to shreds during instantiation.

What about types? Is the data implicitly passed? Is it only primitive
types that we should be passing here? I am assuming passing arrays would
cause a massive ChucK boom?

What about passing arguments to a currently running shred? I am using *
as an imaginary operator that tells ChucK to pass arguments to running

chuck * 1:foo

This feature would be endlessly useful. I would like to write something
like this:

SinOsc s => dac;
440. => s.freq;

true => bool keeplooping;

while (keeplooping = true){
	if( me.argHasMessage(0) ){

Then you could do something like this:

chuck * 1:false

A related feature would be to declare types and max numbers of arguments
for the shred. That way if a passed value violated these declarations
the compiler would throw an error and we could begin the search, lest we

Any light that can be shed on the topic of command line arguments would
be greatly appreciated. The only docs appear to be on the web and not in
the manual. I would love to rectify this.


Enter to win a night a VIP night out at TIFF 

More information about the chuck-users mailing list