I have a track that is 110 BPM
I converted that over to MSecs by 60000/110 (545.455)
I then Divided that by 8 to give me the MS of each tick and then multiplied that by 64 to give me the pattern length in ms (4363.64)
When I go to File>Render to Disk>Selection in Sequence I can see that my song has 45 patterns
I then multiply the length in MS * 45 and get the legnth of the song in MS (196363.8)
The formula I am using is:
(((60000/BPM)/8)*64)*PatternLength = Length of Track in MS
Something is wrong, because when I convert this over to Mins and Secs it doesn’t line up with the mins and secs of the track I’ve just exported.
I’m just hoping someone might be able to see what I’ve done wrong. I’ve double checked and I’m not swinging the track or changing the BPM’s.
Is it off by a tiny amount, a huge amount, or what? It would be useful to know the length of the exported track and get an idea of exactly how wrong/different things are.
3:16.363 is the final output on the Re-noise track
3.27.27 is where I end up
I’ve been working backwards for a bit to see if I’ve messed something up (which I know I have ). I’m not sure if things have a ‘0’ count so that could help here and there.
It’s also quite inaccurate since it rounds to the nearest whole millisecond, so you could potentially introduce a lot of error into your final results. The actual calculations themselves are very simple to begin with, so it’s a waste of time using the delay effect for this if you are trying to calculate any meaningful results.
seconds per beat = 60 / beats per minute
milliseconds per beat = 60000 / beats per minute
Something else I thought about: is the song possibly an old format RNS which used the older (and slightly inaccurate) timing methods, or is it a modern XRNS?
local BPM = renoise.song().transport.bpm
local LPB = renoise.song().transport.lpb
local song_length = 0
for i = 1, #renoise.song().sequencer.pattern_sequence do
song_length = song_length + (60/BPM/LPB * renoise.song().patterns[renoise.song().sequencer.pattern_sequence[i]].number_of_lines)
end