First time here? Check out the FAQ!
x

What are the main differences between Constant and CapytalkToSound for turning a Capytalk expression into Sound?

+2 votes
277 views
What are the main differences between these Constant and CapytalkToSound for turning a Capytalk expression into Sound?  Just getting back into the manual and saw Constant (p 236) and its use with Capytalk. Curious from a pedagogical perspective.
asked Dec 27, 2018 in Capytalk & Smalltalk by jonbellona (Adept) (1,300 points)

1 Answer

+2 votes
CapytalkToSound is the (newer and preferred) way to cross over from the domain of control signals to the world of audio signals. An EventExpression in the value field is evaluated at the control rate and its output is linearly interpolated to output new values at the sample rate. One way to think of it is as evaluating the Capytalk expression in the Value field once per milliseond and then "connecting the dots" with straight lines so the output of this Sound has a new value on every sample. (The older technique of putting Capytalk into a Constant lacks this "connect the dots" interpolation step).
The CapytalkToSound modules reduces quantization noise by linearly interpolating at the sample rate, so it is better for use in an Envelope, Level, or other parameter field that is evaluated at the sample rate. After pasting a CapytalkToSound in a parameter field, remove the L that appears after the pasted Sound. Try to do all arithmetic using Sound modules or in the Value field of the CapytalkToSound (not in the field where you have pasted the CapytalkToSound).
answered Dec 27, 2018 by ssc (Savant) (127,080 points)
Thank you! Perfect.
...