Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Ae wiggle expression jumps after start from specific time.

  • Ae wiggle expression jumps after start from specific time.

    Posted by Nuwan Thilina on November 27, 2016 at 8:57 am

    Hello there, I have added following code to my shape layer.
    This layer is animated in first 2 seconds.

    So I wanted to it to wiggle after a certain time.
    Thanks to CC, I have founded the codes that work.

    But when switching animation from key frames to wiggle there is a jump.
    wiggle start with separate value.

    How to make this transition smooth?

    Your help will be highly appreciated!

    timeToStart = 3;
    if (time > timeToStart)
    {
    w = wiggle(1.5,30);
    [w[0],value[1]]
    }
    else
    {
    value;
    }

    Nuwan Thilina replied 9 years, 5 months ago 2 Members · 4 Replies
  • 4 Replies
  • Xavier Gomez

    November 27, 2016 at 3:48 pm

    You can transition smoothly between the two by using a linear or ease function:

    timeToStart = 3;
    transitionDur = 1;
    freq = 1.5;
    maxAmount = 30;

    amount = easeIn(time, timeToStart, timeToStart+transitionDur, 0, maxAmount);
    [wiggle(freq, amount)[0], value[1]];

    Note: you could also use, with the eact same result:

    timeToStart = 3;
    transitionDur = 1;
    freq = 1.5;
    maxAmount = 30;
    x1 = value[0];
    x2 = wiggle(freq, maxAmount)[0];
    [easeIn(time, timeToStart, timeToStart+transitionDur, x1, x2), value[1]];

    Xavier

  • Nuwan Thilina

    November 27, 2016 at 3:58 pm

    Wow…! This is exactly what I wanted. Spent the whole day trying to figure this out.
    Thank you so much. You saved my tomorrow. ?

    Thanks again,
    Nuwan T.

  • Nuwan Thilina

    November 27, 2016 at 4:30 pm

    One question,

    Can you let me know how to enable both axis(x,y) to animate (wiggle)
    in above expression.

    Thanks.

  • Nuwan Thilina

    November 27, 2016 at 4:44 pm

    My bad Just figured it out.
    Posted the code here. So it may help other users.

    timeToStart = 2.5;
    transitionDur = 1;
    freq = 1.5;
    maxAmount = 50;

    amount = easeIn(time, timeToStart, timeToStart+transitionDur, 0, maxAmount);
    wiggle(freq, amount);

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