Copy link to clipboard
Copied
In this global expression:
timeToTimecode(t = time + thisComp.displayStartTime, timecodeBase = 30, isDuration = false)
Instead of being coded to 30, is it possible for timecodebase to read the current comp's FPS automatically?
Copy link to clipboard
Copied
You can do this:
timecodeBase = 1 / thisComp.frameDuration;
timeToTimecode(t = time + thisComp.displayStartTime, timecodeBase, isDuration = false);
Copy link to clipboard
Copied
There must be some rounding issue, because the timecode generated doesn't match AE's timeline. It's off a few frames.
Copy link to clipboard
Copied
It's hard to say. Could you give a bit more information? i.e. what's your comp frame rate? how does the timecode not match the timeline time display?
Copy link to clipboard
Copied
In a 23.976FPS comp, here are a few of the incorrect times.
The comp starts at frame 0 / time 00:00:00
Copy link to clipboard
Copied
Yes, it seems with a comp frame rate of 23.976 the timeToTimecode() method mostly gives the wrong time, and this happens whether you use timecodeBase = 1/thisComp.frameDuration or timecodeBase = 23.976.
Could you use timeToCurrentFormat() instead? That seems to give the correct results.
Copy link to clipboard
Copied
Maybe. But this is for an animatic template for other designers to use. I can't guarantee if they will be using frames or timecode as the comp's native time format (everyone has their own preference), but I want to be sure to display both.