Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions sourceRectAtTime does not work with text animators

  • sourceRectAtTime does not work with text animators

    Posted by David Cabestany on July 30, 2019 at 8:18 pm

    I’m using sourceRectAtTime with some text layers. As I type the text I can see the background layer growing accordingly, however when I add a text animator so I can have the text build over time the background layer stops animating, it still recognizes the boundaries of the text layer via the sourceRect… expression but it does not animate its size over time.

    Every single example I’ve seen online shows this is possible, but when I add the animator, either with keyframes or expressions it just freezes.

    Any idea why? I’m using CC2019.

    Below is the expression I’m using.

    s=thisComp.layer("xp").effect("Layer Control")("Layer");
    x=s.sourceRectAtTime().width;
    y=s.sourceRectAtTime().height;
    [x,y];

    Paul Ducco replied 2 years, 3 months ago 3 Members · 5 Replies
  • 5 Replies
  • Dan Ebberts

    July 30, 2019 at 11:01 pm

    I don’t think it will work with an Animator. I think you have to actually manipulate the source text to create your type-on effect.

    Dan

  • David Cabestany

    July 30, 2019 at 11:05 pm

    It does, only not with opacity, even at 0% it still reads the characters as fully being there. I changed my animator to scale instead of opacity and it works as expected.

    There are a ton of limitations with this expression, with all the fiddling that has to be done is not that useful.

  • Paul Ducco

    October 26, 2022 at 12:32 am

    Is there a work around for this?
    i.e, being able to get the specific height of the (currently displayed) text block?

    Alternatively…how else does one “manipulate the source text to create your type-on effect”?

  • Dan Ebberts

    October 26, 2022 at 5:07 am

    If you create a type-on effect with a source text expression like this:

    rate = 20;
    value.substr(0,time*rate)

    then

    yourTextLayer.sourceRectAtTime(time,false)

    will give you accurate results.

  • Paul Ducco

    October 26, 2022 at 5:20 am

    You Sir, are a legend. Thankyou.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy