Quantcast
Channel: Adobe Community : Popular Discussions - After Effects Expressions
Viewing all articles
Browse latest Browse all 47983

How to calculate the 4 corners of a text layer?

$
0
0

Hello

 

I need to know how to translate the size of a text layer to get the coordinate of his corners. My need is to be able , in an automatic way, to give a solid the size of a text. For exemple if i write a longer text, the solid increases his size.

I tried this expression but AE (10.0.1) notified me that the Source's function is not defined.

 

var r = thisComp.layer("Layer").sourceRectAtTime(0, false);

alert(r.top + " " + r.left + " " + r.width + " " + r.height);

 

Any idea?


Viewing all articles
Browse latest Browse all 47983

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>