ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

# Easing back Shape layer Trim path Expression

FAQ   •   VIEW ALL
 Easing back Shape layer Trim path Expression on Oct 13, 2018 at 8:56:05 am

Hi,

Please is possible for this expression on Trim path End properties to be adjusted that after it eases from 0 to 100, it will hold the 100 for 5 seconds then it will ease back from 100 to 0?
Thanks

Regards
Obed

minDur = 1;
maxDur = 5;
seedRandom(100,true);
dur = random(minDur,maxDur);
t = time - inPoint;
ease(t,0,dur,0,100);

 Re: Easing back Shape layer Trim path Expressionon Oct 13, 2018 at 1:09:35 pm

Like this maybe:

minDur = 1;
maxDur = 5;
seedRandom(100,true);
dur = random(minDur,maxDur);
t = time - inPoint;
if (t < dur){
ease(t,0,dur,0,100);
}else{
ease(t,dur+5,2*dur+5,100,0)
}

Dan

 Re: Easing back Shape layer Trim path Expressionon Oct 13, 2018 at 1:33:22 pm

That's was perfect!!!
Thanks so much, Dan.

Regards,
Obed

 Re: Easing back Shape layer Trim path Expressionon Oct 13, 2018 at 6:24:15 pm

Hi Dan,
Please, how do remove the random from the expression? I would like to duplicate the shape layer and get an exact copy
Thank you

Regards,
Obed

 Re: Easing back Shape layer Trim path Expressionon Oct 13, 2018 at 7:03:33 pm

You'd have to pick a duration, like this:

dur = 3;
t = time - inPoint;
if (t < dur){
ease(t,0,dur,0,100);
}else{
ease(t,dur+5,2*dur+5,100,0)
}

Dan

 Re: Easing back Shape layer Trim path Expressionon Oct 13, 2018 at 7:18:38 pm