View Single Post
Old 24th September 2015, 15:31   #3  |  Link
kolak
Registered User
 
Join Date: Nov 2004
Location: Poland
Posts: 2,843
I have used this (in my own bash scripting)
From frames to DF timecode:

fps=30

D=$(( frames/17982 ))
M=$(( frames%17982 ))
frames=$(( frames+ 18*D + 2*((M - 2)/1798) ))

# Count frames, seconds, minutes and hours

frame=$(( frames%fps ))
second=$(( frames/fps%60 ))
minute=$(( frames/fps/60%60 ))
hour=$(( frames/fps/60/60%24 ))

It's based on the code provided by some SMPTE guy and works fine even up to 24H TC.
kolak is offline   Reply With Quote