Copy link to clipboard
Copied
I've used Dan Ebbert's trigger animation with markers expression for years and I occasionally have an issue where an animation...glitches for lack of a better term... for a single frame during a render. When I preview the animation in AE, it plays fine. It only seems to happen once if I have multiple comp markers setup for animation.
This is the code I've applied to the Time Remap property of my precomp.
try{
//Trigger and Retime Precomped Animations: Apply to Time Remap
action = comp(name);
n = 0;
if (marker.numKeys > 0){
n = marker.nearestKey(time).index;
if (marker.key(n).time > time){
n--;
}
}
if (n == 0){
0
}else{
m = marker.key(n);
myComment = m.comment;
try{
actMarker = action.marker.key(myComment);
originalStart = actMarker.time;
originalEnd = originalStart + actMarker.duration;
newStart = m.time;
newEnd = newStart + m.duration;
linear(time,newStart,newEnd,originalStart,originalEnd);
}catch (err){
0
}
}
}catch(err){value}
Here's how it looks in a GIF.
The glitch is happening when my "Out" marker triggers.
There aren't any keyframes or changes between comp markers. In this case, no changes between my "Transition" and "Out" markers.
I first thought it might be a framerate issue, but I've verified every comp is using the same frame rate. I've tried rendering to MP4, MOV, GIF. The glitch happens in all of them. Any ideas? Thank you
Copy link to clipboard
Copied
Wanted to add that the frame the glitch happens, it's not the whole frame disappearing. In this case, my text goes slightly transparent and parts of it are cut off. Here's the single frame from the GIF.
Copy link to clipboard
Copied
It's hard to tell without seeing the project. What does the time remapping look like in the graph editor?
Copy link to clipboard
Copied
Copy link to clipboard
Copied
To see the Time Remap graph, you have to turn on the Show Post-Expression Graph gizmo for the Time Remap property of the Ribbon layer in the Main comp (and turn on Edit Value Graph), but once you do that, the graph looks good. There's nothing jumping out at me that would explain your glitch in terms of what the expression is doing.
Copy link to clipboard
Copied
Crazy that you can still learn new things that have been right infront of your eyes for years.
I'm reusing that ribbon a handful of times where I'll need to adjust timing so I thought this was a good implementation of that expression, but perhaps I'll have to go without it or time remap with keyframes.
Thank you for taking a look Dan!
Copy link to clipboard
Copied
Please report back if that makes the glitch go away.
Copy link to clipboard
Copied
I was able to render it fine when using keyframes. However, using hold keyframes still resulted in the glitch during render, as if I was still using the expression and markers. So it seems related to when the time remap jumps in time?
For example, in my Ribbon comp, I have my "Transition" animation occur from 10:00 - 11:00 and my "Out" animation occur from 20:00 - 21:00. In the main comp, when the time remapped Ribbon layer skips from 11:00 to 20:00, it produces the glitch. When I just let the keyframes playout, it renders as it should. Which I guess is fine in this case since I don't have any animation occuring during that time.
In these screenshots, layer #9 renders correctly. Layer #10 and #11 produce the glitch.