Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions referencing xyz position of a layer from a different comp

  • referencing xyz position of a layer from a different comp

    Posted by Nguyencat Le on November 11, 2015 at 2:03 am

    Hello,

    I am scratching my head on how to call the xyz position of layer A in comp 1 at frame “t” and assign them to layer B in comp 2 (different timestamp).

    To do so, I’m assigning a slider to select the frame # in comp 1 and figuring out how to extract the xyz position at that exact frame number and transfer them to a layer in comp 2.

    Could you give me some pointers on where to look at?

    Thank you for your time.

    Nguyencat Le replied 10 years, 6 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    November 11, 2015 at 7:43 am

    This might not be exactly what you’re looking for, but it should give you the position of layer “A” in “comp 1” at the frame specified by a slider:

    s = effect(“Slider Control”)(“Slider”);
    t = framesToTime(Math.round(s));
    p = comp(“comp 1”).layer(“A”).transform.position.valueAtTime(t);

    Dan

  • Nguyencat Le

    November 11, 2015 at 5:14 pm

    Thank you so much Dan. I think it will do it exactly what I need!

    Cheers!

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