Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Accessing position from parented item for use in expressions

  • Accessing position from parented item for use in expressions

    Posted by Shawn Marshall on January 25, 2006 at 2:00 am

    Hello:

    Yet another expression question. I’ve parented a 3D camera to a null (to faciliate arcing around layers arrayed in 3D space) and I’ve parented that null to another (to facilitate moving those parented items in xyz space). That seems convoluted, but it seems to work the best for what I’m trying to do.

    I want to apply the camera’s x position to a fractal tunnel effect position so that when the camera moves to the left the vanishing point of the tunnel will move too. I had a working expression for this, but when I decided to set up this parented relationship that expression stopped working because the camera now has no independent positional keyframes (its x position stays at 0).

    So is there a way to send the camera’s global positional values to that expression? Or is there an alternative way to do this?

    Thank you.

    Shawn Marshall
    Marshall Arts Motion Graphics

    Shawn Marshall replied 20 years, 6 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    January 25, 2006 at 2:30 am

    This should give you the position of the camera in world space:

    C = thisComp.layer(“Camera 1”);
    P = C.toWorld([0,0,0]);

    DAn

  • Shawn Marshall

    January 25, 2006 at 9:26 am

    Dan:

    Once again, thank you for your help.

    Shawn Marshall
    Marshall Arts Motion Graphics

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