ChucK

From Wikipedia, the free encyclopedia

ChucK
the ChucK Operator
Paradigm: multi-paradigm: procedural, object-oriented, on-the-fly programming
Appeared in: 2003
Designed by: Ge Wang and Perry Cook
Typing discipline: strong, static / dynamic
OS: Cross-platform
License: GPL
Website: http://chuck.cs.princeton.edu/

ChucK is a concurrent, strongly-timed audio programming language for real-time synthesis, composition, and performance, which runs on Mac OS X, Linux, and Windows. It is designed to favor readability and flexibility for the programmer, over other considerations such as raw performance. It natively supports concurrency and multiple, simultaneous, dynamic control rates. Another key feature is the ability to add, remove, and modify code on the fly, while the program is running, without stopping or restarting. It has a highly precise timing model, allowing for arbitrarily fine granularity. It offers composers and researchers a powerful and flexible programming tool for building and experimenting with complex audio synthesis programs, and real-time interactive control.

ChucK is free software distributed under GPL.

Contents

[edit] Language features

[edit] Current limitations

The ChucK programming language is relatively young and undergoing significant development. Consequently, there are some features that are not yet included in the language.

Such features include:

[edit] Code example

(The following is a simple chuck program that generates sound and music. See more examples here)

 // our signal graph (patch)
 SinOsc s => JCRev r => dac;
 // set gain
 .2 => s.gain;
 // set dry/wet mix
 .1 => r.mix;
 
 // an array of pitch classes (in half steps)
 [ 0, 2, 4, 7, 9, 11 ] @=> int hi[];
 
 // infinite time loop
 while( true )
 {
     // choose a note, shift registers, convert to frequency
     Std.mtof( 45 + Std.rand2(0,3) * 12 +
         hi[Std.rand2(0,hi.cap()-1)] ) => s.freq;
 
     // advance time by 120 ms
     120::ms => now;
 }

[edit] External links

[edit] See also

In other languages