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.

Playing Back Samples from the Capybara RAM<br />

If you read the samples from Capybara RAM, rather than from disk, you can get greater polyphony at the<br />

expense of a slightly longer wait during the compile step while <strong>Kyma</strong> loads the samples from disk into<br />

the Capybara RAM. For an instrumental-sounding example, try out 20-harp subset in RAM.<br />

If there are too many samples to fit into the RAM of one expansion card, you can split the samples up into<br />

separate folders and assign a different KeyMappedMultisample to each folder. For example, open the<br />

<strong>Sound</strong> called hrp on two exp cards:<br />

Feeding into the Mixer called fullharp sampler are two MIDIVoices: 3 e - 6 e and 2 c - 3 d sharp. Doubleclick<br />

3 e - 6 e and notice how LowPitch and HighPitch are set in the parameter fields. This restricts the<br />

range of MIDI key numbers that can trigger the KeyMappedMultisample. <strong>The</strong> KeyMappedMultisample<br />

has celthrp 3 e as its FirstSample.<br />

Compare this to the lower branch of the signal flow graph. <strong>The</strong> lower MIDIVoice has a different range of<br />

key numbers and a different FirstSample (from a different folder) <strong>for</strong> its KeyMappedMultisample.<br />

Choosing Samples other than by MIDI Key Number<br />

velocity violin is an example of a MultiSample. <strong>The</strong> MultiSample takes a list of samples file names and<br />

an Index. <strong>The</strong> index selects which of the samples should be read the next time the MultiSample is gated.<br />

This allows you to select samples using something other than MIDI key numbers. This example uses<br />

!KeyVelocity * 7<br />

to index into the array of seven samples files.<br />

But why stop with MIDI events? Double-click on live input selects samples and look at the parameter<br />

settings of MultiSample9. This MultiSample is triggered when the input from the GenericSource exceeds<br />

an amplitude threshold. Its Frequency is derived from a frequency tracker on the GenericSource, and it<br />

is scaled by an AmplitudeFollower on the GenericSource. <strong>The</strong> Index selecting which sample to trigger is<br />

determined by the expression:<br />

( freq L * SignalProcessor sampleRate * 0.5 hz) nn removeUnits mod: 5<br />

In other words, it is the frequency of the input in hertz, converted into units of half steps (nn stands <strong>for</strong><br />

note number). <strong>The</strong> units of half steps are removed, because this is just an index, not a frequency. <strong>The</strong>n the<br />

number is taken modulo 5, ‡ so that each half step should trigger a different sample up until the 5th half<br />

step when it starts to repeat the pattern.<br />

‡ Just as a refresher, modulo arithmetic is a kind of circular arithmetic similar to arithmetic you per<strong>for</strong>m every day<br />

when you are figuring out time. Time on a circular clock is usually numbered modulo 12. For example, if it is 9<br />

o’clock and you want to know what the time will be in two hours, you can think (9 + 2 = 11). At 11 o’clock if you<br />

were asked what the time would be in two hours, you would think (11 + 2 = 13) if you were in the military, but as a<br />

162

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

Saved successfully!

Ooh no, something went wrong!