Forums > Max For Live

calculating: ms/seconds in (x) amount of bars at (x) tempo (elapsed time)

May 30, 2012 | 9:04 am

with the total amount of bars taken from a group of clips and the tempo observed from session’s tempo, how can I work out how long these clips will play for in milliseconds or seconds with follow actions?

The idea is to to show the elapsed time of the clips by mapping the result of this calculation to the maximum value on a slider and have a timer output to that slider when the first clip is triggered.
Please advise if there is an easier way to do this…
Thanks!


May 30, 2012 | 9:31 am

[translate bbu ms] with input [n 0 0], where n is the number of bars.


May 30, 2012 | 9:46 pm

I have total number of beats, not bars. This is how I set it up..
And for sending these numbers to the iPad over OSC, will converting the ms value to an int create less latency?
Thanks!

– Pasted Max Patch, click to expand. –

May 30, 2012 | 11:50 pm

According to the OSC standard both int and float are sent as 32-bit values. So it doesn’t matter.


Viewing 4 posts - 1 through 4 (of 4 total)