Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Multiplane expression added manually does not work

  • Multiplane expression added manually does not work

    Posted by David Cabestany on March 18, 2014 at 9:49 pm

    I’m using this expression to create a multiplane expression on my comp:

    camZoom = 2666.6667; distance = position[2] + camZoom; scale * (distance / camZoom);

    When I add it using a script named PSDto3D that I found at motion graphics exchange the expression works fine, however when I revise it to

    camZoom = thisComp.layer(“Camera 1”).transform.position[2]*-1;
    distance = position[2] + camZoom;
    scale * (distance / camZoom);

    which is basically the same, the objects are displaced also in x and y as soon as I start dragging them in z space. The scale works fine according to the expression but there multiplane effect is not achieved, everything moves in a very obvious way.

    Can anybody tell me why the second variation doesn’t work?
    Thanks.

    camZoom = 2666.6667; distance = position[2] + camZoom; scale * (distance / camZoom);

    camZoom = thisComp.layer("Camera 1").transform.position[2]*-1;
    distance = position[2] + camZoom;
    scale * (distance / camZoom);

    David Cabestany replied 12 years, 5 months ago 2 Members · 4 Replies
  • 4 Replies
  • Dan Ebberts

    March 19, 2014 at 12:19 am

    It seems to work fine as long as the layer’s anchor point is on the camera’s z axis. If you have it off-axis, I would think you would need a position expression as well, to keep the layer on the camera’s line of sight that passes through the anchor point.

    Dan

  • David Cabestany

    March 19, 2014 at 12:29 am

    Thanks Dan.

    You mean having the layer’s anchor point “aligned” to the camera’s z axis on its point of interest?

  • Dan Ebberts

    March 19, 2014 at 1:22 am

    Yes, so the layer’s anchor point will be in the center of the camera’s view.

  • David Cabestany

    March 19, 2014 at 3:10 pm

    Thanks a lot again

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