FORUMS: list search recent posts

Shape layer hierarchy confused

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Ilya Sire
Shape layer hierarchy confused
on Apr 27, 2017 at 8:37:33 am

Hello, I have a question about shape layer hierarchy expression as here



how to get opacity from Group 2> Rectangle 1> Opactity?

Please help me
Thank you

thisProperty.propertyGroup(3)(1).transform.opacity


Return to posts index

Xavier Gomez
Re: Shape layer hierarchy confused
on Apr 27, 2017 at 12:55:34 pm

Maybe this:

thisProperty.propertyGroup(6).content("Group 2").content("Rectangle 1").transform.opacity;

or :

thisLayer.content("Group 2").content("Rectangle 1").transform.opacity;

Xavier


thisProperty.propertyGroup(5)("Group 2").content("Rectangle 1").transform.opacity; would also work, but less clear imo.


Return to posts index

Ilya Sire
Re: Shape layer hierarchy confused
on Apr 27, 2017 at 2:57:05 pm

Yes it worked, but could you please explain me why propertyGroup(6)? How did you count it?

thisProperty.propertyGroup(6).content("Group 2").content("Rectangle 1").transform.opacity;

I dont really understand about shape indexing.


Return to posts index


Xavier Gomez
Re: Shape layer hierarchy confused
on Apr 27, 2017 at 4:05:23 pm

In :

thisLayer.content("Group 2").content("Rectangle 1").transform.opacity;

you "get down 6 times" to go from the Layer to the Opacity.
(Layer --> Contents ---> "Group 2" ---> Contents ----> Rectangle 1 ----> Transform ---> Opacity

Hence, the other way round, you need to climb up 6 times to go from the Opacity to the Layer.

One thing to know is that every Shape Group inside a shape layer has a "Contents" and a "Transform"
(similarly to the layer itself having a Contents and a Transform)
The "Contents" step is hidden in the UI though, but it is still there somehow and must be accounted for.

Xavier


Return to posts index

Ilya Sire
Re: Shape layer hierarchy confused
on Apr 27, 2017 at 4:39:23 pm

oh i see it. Thank you for your explanation.

so i learned this way;

1) counting from thisLayer down to property, be like:
thisLayer.content("Group 2").content("Rectangle 1").transform.opacity;
thisLayer.content(2).content(1).transform.opacity;

2) counting from thisProperty climb up to other group, will be like:
thisProperty.propertyGroup(6).content(2).content(1).transform.opacity;

i guess level 6 = thisLayer is maximum


Return to posts index

Kyle Daily
Re: Shape layer hierarchy confused
on Apr 27, 2017 at 2:02:51 pm

You can always pick whip the property to get its syntax.

thisComp.layer("Shape study").content("Group 2").content("Rectangle 1").transform.opacity


Return to posts index


Ilya Sire
Re: Shape layer hierarchy confused
on Apr 28, 2017 at 4:12:36 am

Thank you for this lesson. :)


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]