Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Reverse this expression on Type

New Here ,
Dec 09, 2021 Dec 09, 2021

I folowed this ( https://www.youtube.com/watch?v=LRazU7uNgD0 ) tutorial which allowed me to get a really nice bouncy text animation using this expression:

 

freq = 1;
decay = 7;
duration = 0.10;
retard = textIndex*thisComp.frameDuration*2;
t = time - (inPoint + retard);
startVal = [100,100,100];endVal = [0,0,0];
if (t < duration){
linear(t,0,duration,startVal,endVal);
}else{
amp = (endVal - startVal)/duration;
w = freq*Math.PI*2;
endVal + amp*(Math.sin((t-duration)*w)/Math.exp(decay*(t-duration))/w);}

 

I wondered if it's possible to start the animation from the end of the text and not the start and speed up the animation.

I have attached an example below - I want the bottom line to start from the 'g' and go in just like the top line starts from the 'a' and goes in. 

 

Streatch and Squash text test.gif

 

Appreciate any input. 

 

 

TOPICS
Expressions , How to
406
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Dec 09, 2021 Dec 09, 2021

To get it to go backwards, I think you just need to change this line:

retard = textIndex*thisComp.frameDuration*2;

to this:

retard = (textTotal-textIndex)*thisComp.frameDuration*2;

 

Translate
LEGEND ,
Dec 09, 2021 Dec 09, 2021

Simply revert the text animator or change the t variable to reference the end time by ways of outPoint-retard or something like that. Speeding up the animation simply depends on the parameters defined at the beginning for decay, frequency and duration (per character). Simply play around with them.

 

Mylenium

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 09, 2021 Dec 09, 2021

To get it to go backwards, I think you just need to change this line:

retard = textIndex*thisComp.frameDuration*2;

to this:

retard = (textTotal-textIndex)*thisComp.frameDuration*2;

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 11, 2021 Dec 11, 2021
LATEST

That worked great.

Thank you.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines