Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Non linear spacial interpolation

  • Non linear spacial interpolation

    Posted by Jose Sancho on March 4, 2009 at 8:49 pm

    I´m using the expresions linear(t, tMin, tMax, value1, value2) or ease ( , , , ,) to move an object. I always get a linear space interpolation. Is posible get a non linear space interpolation?

    Thanks

    Filip Vandueren replied 17 years, 5 months ago 3 Members · 6 Replies
  • 6 Replies
  • Filip Vandueren

    March 5, 2009 at 12:38 am

    You’ll have to code your own interpolation method, there’s a lot of prior work done in Flash actionscript that can be reused with some minimal rewriting.

    But what do you need to do that can’t be done using the position keyframing of After Effects?

    There’s no way to get that kind of flexibility with beziers etc.

  • Todd Kopriva

    March 5, 2009 at 4:50 am

    See the “Interpolation methods” section of After Effects Help. It describes several non-linear interpolation methods (mostly eases) and—far more interesting—links to Ian Haigh’s awesome script for adding all sorts of fancy interpolation expressions, including bounces.

    ———————————————————————————————————
    Todd Kopriva, Adobe Systems Incorporated
    putting the ‘T’ back in ‘RTFM’ : After Effects Help on the Web
    ———————————————————————————————————

  • Jose Sancho

    March 5, 2009 at 1:56 pm

    I’m moving my camera through three points (always the same) and I want to control WHEN it´s on them. Actually I’m using markers to control the time.

    Thanks

  • Filip Vandueren

    March 5, 2009 at 3:02 pm

    I would animate the camera using keyframes, make sure the 3 positions occur at time= 0 secs, 1secs, 2 secs , and back at the first position at 3 seconds.

    Then create a slider, and use that to control the timing with a valeAtTime expression.
    Like:

    t=thisComp.layer("Null").effect("TimeSlider").value;
    t=t%3;
    valueAtTime(t);

    Use this expression on position, and maybe also rotations, point of interest etc. of your camera.

    Now you can keyframe the Slider as a sort of timeremapping of the camera’s position.
    Makes sense?

  • Jose Sancho

    March 5, 2009 at 5:27 pm

    Thanks Filip, It works fine. I only have a question about the code. What does % means on the second line?

  • Filip Vandueren

    March 5, 2009 at 11:51 pm

    it’s a mathematical operation called modulo.
    a%b is the remainder of a/b

    so 3%3=0, 4%3 = 1, 5%3=2 etc.
    you’ll always have values between 0 and 3

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