Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions overshoot expression bug

  • overshoot expression bug

    Posted by boaz halperin on August 18, 2024 at 1:12 pm

    hey guys i recently used an expression that creats overshoot in the expression selector via text animators but it seems to be buggy, sometimes it renders just fine, and sometimes it just causes ae to not show a preview, so really the issue comes and goes, when i delete all the cache it seems to be fine, but it becomes more and more often so it gets annoying and the whole expression becomes useless (the expression is from motion script site)

    so this is the expression:

    freq = effect(“Speed”)(“Slider”);

    decay = effect(“decay”)(“Slider”);

    maxDelay =effect(“delay”)(“Slider”);

    delayAddOn=effect(“delay”)(“Slider”)

    seedRandom(textIndex+delayAddOn,true);

    myDelay =textIndex/(0.1+maxDelay);

    t = time – (inPoint + myDelay);

    startVal = [100,100];

    endVal = [0,0];

    dur = 0.2;

    if (t < dur){

    linear(t,0,dur,startVal,endVal);

    }else{

    amp = (endVal – startVal)/dur;

    w = freq*Math.PI*2;

    endVal + amp*(Math.sin((t-dur)*w)/Math.exp(decay*(t-dur))/w);

    }

    for some reason i cant upload here the animation preset

    system specs

    win 10

    AMD Ryzen 9 5900X 12-Core Processor 3.70 GHz

    rtx auros 3080

    32 gb ram

    1 tera hd and another 1 tera for cache

    Yoan Boisjoli
    replied 3 days, 3 hours ago
    3 Members · 8 Replies
  • 8 Replies
  • Dan Ebberts

    August 18, 2024 at 2:29 pm

    >the expression is from motion script site

    Not exactly.

    One thing I notice is that you have the frequency tied to a slider. Is the slider animated at all? That could cause problems.

  • boaz halperin

    August 18, 2024 at 4:03 pm

    thanks dan

    well no not animated just made it for convenience i dont need to animate it since the expression makes all the charm, i dont think the issue is the expression itself since there are times it do work like if i open a new project it works, so this is an odd bug

  • boaz halperin

    August 18, 2024 at 4:05 pm

    one thing i forgot is that its ae 2023 since i encountered many issues in the new 2024 ae

  • boaz halperin

    August 18, 2024 at 5:27 pm

    and if i have the chance to talk with dear dan- anotrher question- how can tweak this same expression in order to make it and out transition meaning instead of creating a decreasing sine wave just make an increasing one- but first offcourse is to make it work without bugs

  • boaz halperin

    August 18, 2024 at 5:34 pm

    now i experimented it in a new project and wham it works

    decay is 7

    delay is 60

    speed is 2

    so how come in a full project it wond render? odd isnt it sherlock?

  • Yoan Boisjoli

    August 19, 2024 at 11:58 am

    Hi Boaz, is it possible that the expression engine wasn’t set to JavaScript in the project settings?

  • boaz halperin

    August 19, 2024 at 4:51 pm

    thanks yoan!

    well i checked that allso but not it was on javascript and i tried to change it to legacy but with no change, so i changed it back to java

    this bug is really obscure cuz when i change the font it suddenly renders, i can manage with it, but mayb someone has a clue where can this bug come from is it a lack of ram? i dedicated ae 29 ram out of 32. mayb the project is too heavy? i dont understand it and i want to have a normal way to work with ae and not get into the house only through the window… so if someone has an idea, that will be lovely

  • Yoan Boisjoli

    September 5, 2024 at 3:49 pm

    The issue might be related to how After Effects is handling memory and cache. Given that clearing the cache temporarily fixes the issue, here are a few steps that could help you troubleshoot the problem:

    1. Cache & memory Issues: Since you’ve already mentioned clearing the cache helps, try adjusting the cache settings in After Effects. You could increase the disk cache size or change its location to a faster drive. Also, close any other unecessary programs while working in AE to free up RAM.

    2. Text Rendering & Font Issues: The fact that changing the font makes it render suggests it might be an issue with how AE is rendering text. Try converting the text layer into shapes or pre-composing the text animation to see if it stabilizes the rendering.

    3. <strong style=”font-family: inherit; font-size: inherit; color: var(–bb-body-text-color); background-color: var(–bb-content-background-color);”>Slider Values: You’re using a slider to control frequency, decay, and delay. Sometimes sliders can cause unexpected behavior, especially when they’re set to extreme values or rounding errors occur. Try clamping the slider values within a reasonable range to see if that helps here’s an example: clamp(effect(“Speed”)(“Slider”), 0, 10)
    4. Out Transition: To modify the expression for an increasing sine wave (rather than a decreasing one), you can reverse the amplitude by multiplying amp by -1 in the overshoot calculation. You could adjust this section of the expression:

    amp = (endVal - startVal)/dur;

    endVal - amp*(Math.sin((t-dur)*w)/Math.exp(decay*(t-dur))/w);

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