ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Re: Automatic Font size script?

COW Forums : Adobe After Effects Expressions

FAQ   •   VIEW ALL   •   ADD A NEW POST   •   PRINT
Respond to this post   •   Return to posts index   •   Read entire thread


Filip Vandueren
Re: Automatic Font size script?
on Mar 30, 2009 at 11:20:14 pm

With scripts it's possible, with expressions it's not.

A script can know the pixel dimensions of a textLayer like this;

// l=yourlayer

rect=l.sourceRectAtTime(l.time,false);

this returns an object with object with four attributes: [top, left, width, height].

so rect.width and rect.height will give you pixel dimensions you can use to calculate the scla you should set your text layer to, to obtain 90% of comp.width (I assume you want to stay within safety)

Does this set you in the right direction, or do you need a kant-en-klaar script ;-)



Posts IndexRead Thread 


Current Message Thread:
  • Automatic Font size script? by janmaarten on Mar 30, 2009 at 7:46:01 pm
    • Re: Automatic Font size script? by Filip Vandueren on Mar 30, 2009 at 11:20:14 pm





© 2019 CreativeCOW.net All Rights Reserved
[TOP]