CAST, "CNMAT Additive Synthesis Tools," is an additive synthesizer in development at CNMAT. CAST must be controlled by messages in the OpenSoundControl protocol.
OpenSoundControl specifies the general format of messages: a URL-style slash-separated address of a particular feature of a particular object in a synth, followed by any number of integer, floating point, or string arguments.
This document explains the organization of OpenSoundControl-addressable objects within softcast and lists all the messages you can send them.
At the moment there are 3 main objects at the top level of the OpenSoundControl address space in CAST. We indicate the top of the address space with a single slash ("/"). These objects are:
Most of the messages you will send to the synth will be sent to a particular voice. The exceptions are messages that apply to the entire synth:
|/synth/gain||float gain scaler||Scales the overall output level of the synth.|
|/synth/noisegain||float gain scaler||Scales the level of the synthesized noise|
|/synth/ofilestart||[none]||Starts recording the synth's audio output to the file specified by the -ofile flag.|
|/synth/ofilepause||[none]||Pauses recording of the synth's audio output to the file specified by the -ofile flag.|
|/synth/quit||[none]||Quits the synth|
The "ofilestart" and "ofilepause" messages work in conjunction with the "-ofile" command-line flag. If you name a sound file with "-ofile", then the synth opens a file with the given name as it starts up. As soon as you send the /synth/ofilestart message, all of the synth's audio output will be written to this file (as well as sent to the audio output of the SGI). This will generally cause the clicking artifacts that come from overloading the CPU, because the processor is writing a lot of data to disk as well as doing the normal synthesis work. However, the audio in the sound file will not have these clicks. The /synth/ofilepause message pauses this sound file recording until the next /synth/ofilestart message. The file is closed when you quit the synth.
The sampling rate and number of channels in the audio file are the same as those of the synth. The file always contains 16-bit samples.
The message /documentation/all-messages will cause the synth to print a list of all the messages it understands. The information in that list is essentially the same as the information in this document, except that it is more terse but more likely to be up-to-date. (That list is generated directly from the source code, so it will reflect any features that have been added but not yet described in this document.)
The CAST synthesizer is polyphonic and multitimbral. Most of the messages you'll send to the synth will be sent to individual voices of the synth. These messages set the timbral prototypes that a voice plays, start and stop the motion of virtual time, manipulate timbre, etc. Each message sent to a voice affects only that one voice. The number of voices in the synth is determined when the synth starts up by the "-voices" flag (or by synthconfig).
The OSC address /voices is the set of all voices in the synthesizer. Voices have numbers starting from 0. So if you start the synthesizer with 3 voices, their addresses will be /voices/0, /voices/1, and /voices/2. Voices 0-51 also have single-letter names: /voices/A is another name for /voices/0, /voices/B for /voices/1, /voices/Z for /voices/26, /voices/a for /voices/27, /voices/z for /voices/52, and so on.
Each voice consists of a series of "transforms" that produce and modify the sinusoid amplitudes and frequencies that will be synthesized. To affect the behavior of one of these transforms, you must send a message to that transform. For example, there is a transform named "vibrato" with a parameter "speed." To set the vibrato speed for voice 2, you'd send the message /voices/2/vibrato/speed. In general, most of the messages you send will be of the form /voices/voice_number/transform_name/message_name.
The documentation for each transform will give only the name of the transform and the list of messages that the transform understands; it's up to you to know how to add the voice information to create an OSC address.
For each voice the softcast synthesizer executes a sequence of transforms. In future versions this sequence can be set in real-time. The built-in default sequence (as of the date of this document) is as follows:
Click on any of the transform names to get a description of that transform and a list of its parameters.
A floating point number that will be multiplied by a gain value. When this kind of parameter is 1.0, the gain is unchanged. When it's 2.0, the gain is doubled, giving a 6 dB rise in volume. When it's 0, the result is silence.
A floating point number that specifies a speed factor for some process (e.g., playing back the additive synthesis data from a timbral prototype). A rate of 1.0 means the original speed. A rate of 2.0 means double speed. A rate of -1.0 means backwards at the original speed. A rate of 0.0 means for time not to advance at all.