Every other frame

Moderators: Disciple, zlovatt

Post Reply
ahettinger
Posts: 13
Joined: March 5th, 2008, 11:48 am

I've got an animated layer, and my comp is 30fps, but I want this layer to update every other frame (or maybe every 3rd or 4th frame), so it will appear to be running at a lower frame rate. Is there an easy way to do this with an expression? In this particular case, I'm just animating the position values.

My workaround so far has been to use the wiggler with a magnitude of 0 and a frequency of 15 to insert keyframes (every other frame) then setting them all as holds. This has been working well, but if I want to tweak my animation, I have to remove a bunch of keyframes and repeat the process, which is messing up my workflow.

Thanks as always!
ahettinger
Posts: 13
Joined: March 5th, 2008, 11:48 am

Ok, got my answer.

Code: Select all

posterizeTime(15);
value;
explorer
Posts: 17
Joined: March 1st, 2007, 11:12 pm
Location: Poland, Warsaw

You can also try doing it like this. Your solution is in fact easier, but might not work for all cases.
I'm not saying this one will. It's just a different approach.

Code: Select all

currentFrame = timeToFrames(t = time + thisComp.displayStartTime, fps = 1.0 / thisComp.frameDuration, isDuration = false);

if(currentFrame % 2 == 0){
     // do this
} else {
    // do that
}
Post Reply