Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Forums Adobe After Effects Expressions X position move based on markers

  • X position move based on markers

  • Olly Starkey

    November 25, 2019 at 3:43 pm

    Hey all

    Dan Ebberts wrote this expression last year.

    m = marker;
    moveTime = .5;
    moveAmt = 1734;
    n = 0;
    if (m.numKeys > 0){
    n = m.nearestKey(time).index;
    if (time < m.key(n).time) n–;
    }
    if (n > 0){
    t = time – m.key(n).time;
    x = (n-1)*moveAmt + linear(t,0,moveTime,0,moveAmt);
    value + [x,0]
    }else
    value

    It’s brilliant but I wonder how to add an easy ease into the motion.

    Is this possible?

    Thanks in advance

  • Dan Ebberts

    November 25, 2019 at 5:03 pm

    Try changing this line:

    x = (n-1)*moveAmt + linear(t,0,moveTime,0,moveAmt);

    to this:

    x = (n-1)*moveAmt + ease(t,0,moveTime,0,moveAmt);

    Dan

  • Olly Starkey

    November 25, 2019 at 5:25 pm

    Of course! Thanks Dan, amazing.

Viewing 1 - 3 of 3 posts

Log in to reply.

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