k y m a • t w e a k y — the kyma collective || view the current website || February 2015 Archive

/ WebHome / How.LoopWhenFrequencyChanges

Search


How Section


How do I...
Add a question...

Home 
Topics 
More... 

All Sections


Products
Order
Company
Community
Share
Learn

Login / Register 
Change password
Forgot password?
%SESSION_IF_AUTHENTICATED% Site Map
%SESSION_ENDIF%

Symbolic Sound


Home
Kyma Forum
Eighth Nerve

TWiki Links


%SESSION_IF_AUTHENTICATED% TWiki Shorthand
TWiki Formatting FAQ
What is TWiki?
%SESSION_ENDIF% twiki.org

Question (or Task)

I have a sample I want to loop seamlessly at a random frequency/pitch every time the sample loops again. So I use the SampleFileDuration? to generate a random number that I multiply by the frequency of my sample. But the duration (length) of my sample changes according to its frequency and so when it triggers the sample again with a different pitch, my sample has either already looped again or it's still playing...

-- JeanEdouardMiclot - 21 Apr 2010

Solution(s)

In this example, I used SoundToGlobalControllers to generate the random duration scale factor and !Gate for the Sample.

The random duration scale factor is:

!Gate nextRandom abs

which gives a scale factor between 0 and 1. To get a scale factor between 0 and 2, you could instead use

!Gate nextRandom + 1

Instead of checking the Loop box, I generate a !Gate using:

('count.aif' sampleFileDuration * !DurScale) s tick

This generates a gate once every (scaled) duration of the sample.

-- CarlaScaletti - 16 May 2010

WebForm
Question: How do I loop when the frequency changes?
Keywords: Sample Loop Random Frequency Duration Length SampleFileDuration?

 
 
© 2003-2014 by the contributing authors. / You are TWikiGuest