4 Replies Latest reply on Apr 19, 2015 2:13 AM by Sulaco

    Can I use loop_out("cycle",0) on a Mask Path

    Sulaco Level 3

      I am currently creating an animated Mask Path that I would like to loop using expressions. But when I try to use "loop_out("cycle",0)" I get a "loop is not supported for custom properties" error. After doing some goggling it seems that it is not possible to use the loop function on a Mask Path. At least not in older version of AE, is this still the case in the latest version? If so, is there a way around it? I found someone who made an rather complex expression that simulated the "loop_out("pingpong",0)" that seemed to work, but I need the cycle one. Could anyone come up with an expression that would simulate this? And please keep in mind, I have very little experience when it comes to expressions and frankly math scars me ...

        • 1. Re: Can I use loop_out("cycle",0) on a Mask Path
          Mylenium Most Valuable Participant

          No, you cannot use these expressions on masks due to their compound keyframes. Depending on what the mask is actually used for, pre-composing it on a separate layer and using that layer as a matte with time-remapping will work.



          • 2. Re: Can I use loop_out("cycle",0) on a Mask Path
            Sulaco Level 3

            Thanks for your reply Mylenium! I was afraid that was the case. I am not sure if what you suggest will work for me, I don't use AE that regularly so I tend to get a bit rusty on how certain things are done. I will have a look at it. But if anyone has an actual expression that simulates Cycle, don't be afraid to post it .... If all else fails I suppose I can always do copy/paste, but it's a bit awkward since the animation I am tracking is a looping one and it would be so convenient to use an loop expression, makes it easier for me to find the loop points of the animation I am tracking...

            • 3. Re: Can I use loop_out("cycle",0) on a Mask Path
              Rick Gerard Adobe Community Professional & MVP

              If you want to cycle an animated mask then just do as Mylenium suggested. If you're a bit rusty here is a step by step:

              1. Create a new solid and add it to your timeline
              2. Add your mask path
              3. Press Alt/Option + M to set the first keyframe for the mask (or click the mask path stopwatch
              4. Set the other keyframes you need for the mask path
              5. After you have set at least two keyframes for the mask move the CTI (current time indicator) down the timeline to the point where you want the animation to loop
              6. Select the first mask keyframe and copy and paste
              7. Move the CTI back one frame and note the CTI position or set a timeline marker
              8. Precompose the masked layer moving all attributes
              9. With out moving the CTI select Layer>Time>Enable Time Remapping or press  Alt/Option + Ctrl/Cmnd + t
              10. Set a new keyframe for Time Remapping at the current time
              11. Delete the last keyframe for time remapping so you only have 2
              12. Add an expression to Time remapping by holding down the Alt/Option key and clicking the stopwatch press Shift + Alt/Option + = and type loopOut();

              There you go. If you need to use the animated mask as a matte then use the pre-comp as a track matte. If you are using the animated mask for something else let us know and we will tell you how to do the work around. BTW, this will work for any property you want to animate that will not work with a loopOut() expression.

              Screen Shot 2015-04-18 at 4.46.17 AM.png

              NOTE: If you want to use the default loopOut("cycle", 0) behavior you don't need to type anything in the brackets. The options inside the brackets are "cycle" and "pingpong" and if needed you can set the number of keyframes you want to loop

              • 4. Re: Can I use loop_out("cycle",0) on a Mask Path
                Sulaco Level 3

                Thanks for the step by step Rick! I will have a look into it ....