Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Anchor a shape to another line shape end point

  • Anchor a shape to another line shape end point

    Posted by Davide Mitidieri on June 10, 2016 at 7:39 pm

    Hi,
    I’m trying to animate a sort of “sign”. It is made of a line which can move, and two rectangles (that are in another shape layer). I managed to fix the rectangles to the line by putting them in the same layer. However, now I want the line to rotate around the starting point of the line. I tryed creating two different layers, one for the line and another for the rectangles, but I can’t manage to make the rectangles fixed to the end of the line, when the inclination changes..

    Here some images to explain it better:

    Before the line rotation
    https://i67.tinypic.com/21o2ceh.png
    After the line rotation
    https://i67.tinypic.com/f1hcte.jpg

    Thanks in advice.

    Walter Soyka replied 10 years, 2 months ago 2 Members · 5 Replies
  • 5 Replies
  • Davide Mitidieri

    June 11, 2016 at 7:46 am

    I tryed in a new comp and it worked. However, my rectangle is following a mask path… and I don’w know why, but when I link the expression of the end point to the rectangle position (which has the anchor point to the lower right corner), the beam end point doesn’t attach to it, but goes away to a strange position out of the screen… what’s going wrong?

    https://i68.tinypic.com/qoymwo.png

  • Davide Mitidieri

    June 11, 2016 at 8:12 am

    P.S.: my rectangle is following a mask path through another layer (“track layer”) in which I pasted the mask path properties. The expression of the start point of the beam is linked to the track layer, and it works fine. Instead, I have problems with the rectangle. The end point of the beam seems to be fixed during the animation (see the red circle marked in the preovius screenshot), while the rectangle moves following the track layer.

  • Davide Mitidieri

    June 11, 2016 at 8:45 am

    Ok, I fixed the problem with this expression:
    m = thisComp.layer("Label");
    m.toComp(m.anchorPoint);

    Where “Label” is the shape containing the rectangle.

    However, now I have one last problem. I set the beam as a 2D layer, otherwise it was overlapping the map, as you see in this picture: (the white line should track the red path)

    https://oi65.tinypic.com/23tphys.jpg

    However, it seems that if there is a 2D object, all the other 3D objects are not casting shadows anymore… how can I fix this?
    1) Keeping the beam layer in 2D, how can I manage to keep the other layers casting shadows?
    2) Converting the beam layer to a 3D object, how can I avoid overlapping with the map?

    Thanks in advice.

  • Davide Mitidieri

    June 11, 2016 at 2:44 pm

    1) The map can rotate, so the view constantly changese, but the camera stays in a fixed position.

    2) The problem is that as soon as the beam is set as a 2D object, also all the other 3D objects (such as other labels, etc.) stop casting shadows… not only the label attached to the beam. I can’t get why it happens…

  • Walter Soyka

    June 13, 2016 at 2:35 pm

    A 2D layer in between 3D layers affects their intersections and lighting. If you have separated the light from the other 3D objects, the shadows won’t render. Put the 2D layer at the top or at the bottom of the 3D layer stack to get your intersections back.

    See here for more:
    https://helpx.adobe.com/after-effects/using/3d-layers.html#3d_layer_interactions_render_order_and_collapsed_transformations

    Walter Soyka
    Designer & Mad Scientist at Keen Live [link]
    Motion Graphics, Widescreen Events, Presentation Design, and Consulting
    @keenlive   |   RenderBreak [blog]   |   Profile [LinkedIn]

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