Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Loop between 2 keyframes in a middle of animation

  • Loop between 2 keyframes in a middle of animation

    Posted by Franck Mony on January 25, 2024 at 9:57 pm


    I have this animation
    1st keyframe : 0s
    2nd keyframe ; 30s
    3rd keyframe : 35s
    4th keyframe : 4 mn
    5th keyframe : 5mn

    I would like to know how could i loop between the 2nd and the 3rd, the loop would last 3.25mn until it reach the 4th keyframe to continue the animation.

    Is it possible to achieve this with simple expression ?

    Brie Clayton replied 1 month ago 3 Members · 3 Replies
  • 3 Replies
  • Dan Ebberts

    January 25, 2024 at 10:17 pm

    Maybe something like this:

    t2 = key(2).time;
    t3 = key(3).time;
    t4 = key(4).time;
    t = time;
    if (time >= t3 && time < t4){
    t = t2 + (time - t3)%(t3 - t2);
  • Franck Mony

    January 25, 2024 at 11:39 pm

    Wow that’s working perfectly, thx you very much Dan !

  • Brie Clayton

    January 26, 2024 at 1:43 am

    Thanks for solving, Dan!

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy