Trigger animation with comp markers - glitch during render
- June 21, 2024
- 2 replies
- 1883 views
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
