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

/ WebHome / How.SetMemoryRecorderDuratio


How Section

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


All Sections


Login / Register 
Change password
Forgot password?

Symbolic Sound

Kyma Forum
Eighth Nerve

TWiki Links

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

Question (or Task)

I want MemoryWriter durations to be expressed in relationship to the duration of beats (i.e. BPM). I can do it with a fixed tempo with an expression like this -- 90 bpm s. But instead of being fixed (at 90, in this case) I would like to to be a "hot" parameter, so if I change the BPM for the TimeLine?, all the MemoryWriters will automatically adjust to the new beat.

Meanwhile ... can someone explain why the following would happen in a TimeLine?. I have two instances of a MemoryRecorder? on a single track. It doesn't matter what the duration setting is for the 2nd MemoryRecorder?, it ends up being the having same duration as the first one on the track. ?!?!?

-- MarkPhillips - 01 Nov 2009


For a "hot" BPM parameter, you can use the same construction you are using for a fixed BPM, namely,

!BPM bpm s

to give you the duration of one beat at !BPM in terms of seconds. This will be bound to the BPM value in the Timeline (or you can set the Timeline BPM to be live).

-- CarlaScaletti - 02 Nov 2009

Well that's what I thought, too. But the reason I originally posted my question is because I could not get this (or anything comparable) to work. If I put !BPM bpm s into the duration box, it simply will not compile. I have uploaded one example file. See attachment below. It works as is, with "hard-wired" or fixed tempo (90). But on my system is does not work with an sort of "hot" parameter standing in for "90"

-- MarkPhillips - 02 Nov 2009

In this situation, the key is, not to capture exactly one beat, but instead to capture a longer amount of time and play back exactly one beat. In other words, if !BPM is a hot value, there is no way to know in advance exactly how much memory to allocate for the recording so instead we can think of the MemoryWriter CaptureDuration parameter as the maximum duration you might want to record. Once you've recorded what you want in the memory buffer (actually you've recorded even longer than you actually need), you can play back exactly the duration you do want by setting the End point in the Sample.

Here is your example modified so the MemoryWriter has a CaptureDuration of 10 s (more than enough in this case). The End value of the playback Sample is set to:

!BPM bpm s / 10 s

This tells the sample to play from the beginning of memory and stop at one beat (defined by the current value of !BPM). Sample expects an End value in the range of 0 to 1 (where 1 is the total duration of the recording), which is why we've used the ratio of the desired duration in seconds to the total duration of the buffer in seconds.

-- CarlaScaletti - 04 Nov 2009

Thanks!!! It works perfectly. And I actually completely understand how it works (which is not always the case) ;-)

-- MarkPhillips - 06 Nov 2009

Question: How do I correlate a MemoryWriter?'s duration with a Timeline BPM?
Keywords: Memory Writer Duration BPM

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