ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

parenting scale problem

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
aniello ferrone
parenting scale problem
on Oct 8, 2019 at 4:44:23 pm

Hi, could you help me?
I have a text layer parented to a shape layer with the pick-whip tool. I want the text layer to follow the shape layer in everything but no for the scale. How can I do it? The layer are both 2D

Thx in advance

Return to posts index

Alex Printz
Re: parenting scale problem
on Oct 8, 2019 at 4:56:22 pm

Try this

p = thisLayer;
s = [1,1];
while (true){
if( ! p.hasParent) break;
p = p.parent;
for(i=0;i<p.scale.value.length;i++) s[i] *= p.scale[i]/100;
for(i=0;i<p.scale.value.length;i++) s[i] = value[i] / s[i];

Alex Printz
Mograph Designer

Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2020 All Rights Reserved