Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity › Forums › Adobe After Effects Expressions › Applying complex Keyframe values to another comp… AND rearranging the keys!

  • Applying complex Keyframe values to another comp… AND rearranging the keys!

    Posted by Ed Nudnick on April 29, 2013 at 4:17 pm

    Hi.

    I have a series of keyframes in for an animated mask shape (maskA) on SolidA in compA.
    And, let’s say its keys are:
    key(1)
    key(2)
    key(3)

    A duplicate solid (SolidB) with a duplicate mask (maskB) is in another, compB.

    What I’d like to do is, by animating a controller (of some kind), I’d like to apply the key values to SolidB’s maskB. But, I’d also like to be able to apply those values in a different order while still allowing them to interpolate.

    So, in compB, SolidB’s key values would be from keys set on SolidA… But, potentially rearranged like so:
    key(3), key(2), key(1), key(3), key(1), key(2), etc…

    I’m a bit of a noob. So, I’d love any suggestions in where to start with the code as well.

    Dan Ebberts replied 13 years, 5 months ago 2 Members · 1 Reply
  • 1 Reply
  • Dan Ebberts

    April 29, 2013 at 5:02 pm

    Access to mask paths is pretty limited in expressions. You can get the shape at a specific times by using valueAtTime(), but you can’t do any math on them, so interpolating won’t work unless that specific interpolation already exists in the source mask. So using your example, you could get the interpolation between keys 1 and 2 and between keys 2 and 3 from the original mask, but not between keys 1 and 3 since that interpolation doesn’t exist.

    Dan

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