09.12.2012 Views

The Kyma Language for Sound Design, Version 4.5

The Kyma Language for Sound Design, Version 4.5

The Kyma Language for Sound Design, Version 4.5

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Using Values with Units in Calculations<br />

<strong>The</strong> rules of regular arithmetic with units apply to parameters that have units of time or frequency. For<br />

instance, you can multiply a value with units by a number with no units, but if you are adding two values,<br />

one of the following conditions must apply: both must be in units of time, both must be in units of<br />

frequency, or both must be without units.<br />

If the values being combined are of the same type (both in units of time or both in units of frequency), but<br />

are not the same units, the calculation will be per<strong>for</strong>med in units of hertz or seconds:<br />

Example Value<br />

60 nn hz 261.6256 hz<br />

100 hz nn 43.35 nn<br />

60 nn + 100 hz 361.6256 hz<br />

60 nn + 100 hz nn 103.35 nn<br />

60 nn hz + 100 hz 361.6256 hz<br />

If you want to remove the units after per<strong>for</strong>ming a conversion or calculation, use removeUnits. For example,<br />

if you needed to use a pitch in units of hertz in computing the value of a non-frequency field, you<br />

would need to remove the units, as in the following code:<br />

4 c hz removeUnits / SignalProcessor sampleRate.<br />

A SMPTE time or duration can be specified as<br />

hours:minutes:seconds.frames SMPTE<br />

as in the following example:<br />

1:04:32.2 SMPTE<br />

Closing the <strong>Sound</strong> Editor and Saving Changes<br />

To close the <strong>Sound</strong> editor, click in the close box at the upper left. <strong>Kyma</strong> will ask whether or not you want<br />

to keep the changes you have made. At this point you have a choice of replacing the old <strong>Sound</strong> with the<br />

edited version, dropping the changes that you just made, or changing your mind and canceling.<br />

If you want to save the edited <strong>Sound</strong> as a new <strong>Sound</strong> while keeping the original <strong>Sound</strong> unchanged, drag<br />

the rightmost <strong>Sound</strong> from the signal flow diagram into a <strong>Sound</strong> file window; then close the <strong>Sound</strong> editor,<br />

and choose No when it asks if you want to save the changes.<br />

Note that changes made to a <strong>Sound</strong> are not saved onto the disk until you have saved the entire <strong>Sound</strong> file<br />

window. To do this, choose Save or Save as… from the File menu.<br />

471

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!