timecode
timecode copied to clipboard
Float property inaccurate?
I could be wrong but I think the float property is not returning the correct value:
https://github.com/eoyilmaz/timecode/blob/bde846369039adb72d028e9e5234c6e655fdcde8/timecode/init.py#L532
I'm working with 23.976 timecode and this property seems to be giving me incorrect results, I had to change it to:
return float(self.frame_number) / (float(24000) / 1001)
So frame_number instead of frames to use the 0-based number rather than 1-based. 24000/1001 is not really necessary in most cases, but at large timecode values you may lose some time when dividing by 23.976