Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Creating a loop

  • Creating a loop

    Posted by Ross Kidd on September 3, 2008 at 4:19 pm

    Hi,

    I have a small animation that runs 300 frames (10 seconds) All I want to do is loop the last 2 secs so in flash I would do a gotoAndPlay (240) on the last frame. How can I achieve this is after effects

    Mike Clasby replied 17 years, 8 months ago 4 Members · 5 Replies
  • 5 Replies
  • Peter Last

    September 3, 2008 at 4:45 pm

    Add flash effect at the end of your animation.
    Render last 60 frames to a sequence. Import it. And in interpret properties (right click on imported footage -> Interpret Footage) set Loop parameter to 100 (or any).
    Add that new footage to the end of your animation.

  • Ross Kidd

    September 3, 2008 at 6:10 pm

    Add flash effect at the end of your animation.
    Render last 60 frames to a sequence. Import it. And in interpret properties (right click on imported footage -> Interpret Footage) set Loop parameter to 100 (or any).
    Add that new footage to the end of your animation.

    I need to explain myself. There is no flash animation I was just explaining (or trying to) how I would do a frame loop in flash. Is there no way to loop frames x to y in AE?

  • Mike Clasby

    September 3, 2008 at 6:34 pm

    I have a small animation that runs 300 frames (10 seconds) All I want to do is loop the last 2 secs so in flash I would do a gotoAndPlay (240) on the last frame. How can I achieve this is after effects ” TARGET=_blank>I have a small animation that runs 300 frames (10 seconds) All I want to do is loop the last 2 secs so in flash I would do a gotoAndPlay (240) on the last frame. How can I achieve this is after effects

    OK, not as easy as Flash but this works. Split the layer and add a loop expression.

    In the timeline, go to the spot you want to be where the loop starts (frame 240) and Edit>Split Layer.

    Select the newly created top layer, and Layer>Enable time remapping. This adds two keyframes to that layer. Add a Time remapping keyframe at that frame 240 (click the Add keyframe box, just below the eyeball). Delete the timeremapping keyframe at the very beginning of the upper layer, there should now be only two time remapping keyframes, one where you want the animation to begin looping, the other where the animation finished it’s cycle.

    Add an expression to Time Remapping, Alt-Click the Time remapping Stopwatch an paste in this:

    loopOut()

    Now on that upper layer grab the right hand edge and extend the layer to the right (lengthen it time-wise so it can loop).

    That’s it.

    Maybe there’s a more elegant way but this works.

  • Darby Edelen

    September 3, 2008 at 9:52 pm

    An easier way to do this might be to enable time-remapping on the layer. Then create an additional keyframe at 240 frames (8 seconds) but don’t change its value. Then apply this expression to the time remap property:


    loopOut("cycle", 1);

    What this tells AE to do is cycle the values between the second to last and last keyframe over and over and over again.

    The default value is loopOut("cycle", 0) which would cycle all values between the first and last keyframe of the property. If you provide a positive number in the second parameter then loopOut() counts back from the last keyframe to decide which keyframe to begin the loop from.

    There are also additional options outside of “cycle” including:

    “continue” – continues the rate of change of the property at the last known rate of change.

    “pingpong” – the value oscillates back and forth from the value at keyframe A to keyframe B back to keyframe A.

    “offset” – the ending value of the looping section is used as the starting value of the next loop segment.

    Here’s a good video that shows these behaviors:

    Note that the position property is what is looping in the above sample, and the arrow has auto-orientation turned on to make it more clear.

    Darby Edelen

    NVIDIA
    Santa Clara, CA

  • Mike Clasby

    September 4, 2008 at 1:44 am

    Thanks, Darby, I figured there’d be a more elegant-straightforward way.

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