Highlighted

Make 'points follow nulls' Nulls appear right above selected layer?

Engaged ,
Feb 16, 2018

Copy link to clipboard

Copied

Hi, I'm wondering if it is possible somehow to have the nulls created from the new 'points follow nulls' expression appear right above the selected layer? For instance, if I want to create nulls for the points on a layer that is maybe 50 or 60 layers down, then the nulls show up at the very top of the comp. I'd like to have them right above the layer that they are controlling. Anyone know if this is possible via preferences or something?

Thanks.

Views

1.5K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Make 'points follow nulls' Nulls appear right above selected layer?

Engaged ,
Feb 16, 2018

Copy link to clipboard

Copied

Hi, I'm wondering if it is possible somehow to have the nulls created from the new 'points follow nulls' expression appear right above the selected layer? For instance, if I want to create nulls for the points on a layer that is maybe 50 or 60 layers down, then the nulls show up at the very top of the comp. I'd like to have them right above the layer that they are controlling. Anyone know if this is possible via preferences or something?

Thanks.

Views

1.5K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Feb 16, 2018 0
Community Beginner ,
Mar 21, 2018

Copy link to clipboard

Copied

Hi, I encountered this issue today, except the shape I'm trying to use the expression on only has 4 points.

The nulls that were created by 'Points Follow Nulls' also appeared in the wrong spot, they seem to be off by X: -35px and Y: -138px, which makes it tricky when trying to parent the nulls to other animated layers.

I'm not sure what causes it - and I've tried resetting the scale of the shape and unparenting it to no avail - but I was able to create a temporary fix.

Basically, on the shape layer, add two Slider Controls - name them OffsetX and OffsetY

Then on your shape layer's path property and change the last for loop in the expression from this:

for (var i = 0; i < getNullLayers.length; i++){

    if (getNullLayers != null && getNullLayers.index != thisLayer.index){

          origPoints = fromCompToSurface(getNullLayers.toComp(getNullLayers.anchorPoint))

    }}

To this:

for (var i = 0; i < getNullLayers.length; i++){

      if (getNullLayers != null && getNullLayers.index != thisLayer.index){

          point = fromCompToSurface(getNullLayers.toComp(getNullLayers.anchorPoint));

          origPoints = [ point[0]+effect("OffsetX")("Slider"), point[1]+effect("OffsetY")("Slider") ];

    }}

Now you can adjust the OffsetX and OffsetY sliders until the nulls are actually over the shape.

Obviously not perfect, there's probably an easier solution - but don't have time to keep searching for one right now.

Hope this helps,

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 21, 2018 1
New Here ,
Jun 07, 2018

Copy link to clipboard

Copied

The issue is that the Position value for the shape inside the shape Transform properties - not the layer position - has to be 0,0. Else, it offsets the nulls.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jun 07, 2018 3
New Here ,
Oct 26, 2020

Copy link to clipboard

Copied

instagram

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 26, 2020 0