Forum Replies Created

Page 2 of 9
  • Yoan Boisjoli

    November 7, 2024 at 1:24 am in reply to: Offset animation, then loopOut.

    Alright I got something like that to work. I’m animating the slider with hold keyframes but feel free to try something else. I’m joining a screencast of how it’s behaving and my ae file also.

    // Time Offset from Slider
    var offset = effect("Slider Control")("Slider")/10; //dividing it by 10 becasue it's sensitive
    // Total duration of the loop (from first to last keyframe)
    var firstKeyTime = key(1).time;
    var lastKeyTime = key(numKeys).time;
    var loopDuration = lastKeyTime - firstKeyTime;
    // Current Time adjusted by the offset
    var adjustedTime = time - offset;
    // Calculate the looped time
    var loopedTime = (adjustedTime - firstKeyTime) % loopDuration + firstKeyTime;
    // Ensure loopedTime doesn't go below the first keyframe time
    loopedTime = (loopedTime < firstKeyTime) ? firstKeyTime : loopedTime;
    // value at the looped time
    valueAtTime(loopedTime);


  • Yoan Boisjoli

    November 7, 2024 at 12:45 am in reply to: Offset animation, then loopOut.

    Hi Griffin! Is the property only one value or an array of 2 or more?

  • What I do is hold ‘Alt’ while pickwhipping a property, which makes it universal by addressing the index. However, at the end of a project, when I need to make it available in any language, I use the script Expression Universalizer.

  • If you set up a paragraph text box in After Effects, you can use an expression on sourceText to pull in text from your CSV and it’ll split the lines automatically to fit within the box. Something like this:

    txt = footage("yourCSVfile.csv").dataValue([0, 0]); // Change this to point to your CSV file and correct cell

    txt;

  • Hi Matthew! Are you talking about a paragraph text box?

    In after effects if you simply drag a square with the text tool you can make a paragraph text box.

    Let me know if this is what you are referring to.

    Cheers.

  • There’s also this tutorial where it’s well explained:

    https://youtu.be/flnRYVMbMmQ?si=Ejxt5r98d4XQY7wb

    Some contents or functionalities here are not available due to your cookie preferences!

    This happens because the functionality/content marked as “Google Youtube” uses cookies that you choosed to keep disabled. In order to view this content or use this functionality, please enable cookies: click here to open your cookie preferences.

  • Here’s a helpful tutorial:

    https://youtu.be/-n0RKDlbGas?si=abArBOJvLzdZy0NZ

    Is this what you’re aiming for?

    Some contents or functionalities here are not available due to your cookie preferences!

    This happens because the functionality/content marked as “Google Youtube” uses cookies that you choosed to keep disabled. In order to view this content or use this functionality, please enable cookies: click here to open your cookie preferences.

  • Dan is right—expressions don’t store previous values and will only access the pre-expression value when referencing their own property. To hold the position after 10 seconds, you can use valueAtTime(duration) to “freeze” the last calculated position:

    var duration = 10;

    if (time < duration) {

    var progress = time / duration;

    [

    linear(progress, 0, 1, value[0], value[0] + 100),

    linear(progress, 0, 1, value[1], value[1] + 100)

    ];

    } else {

    valueAtTime(duration);

    }

  • Yoan Boisjoli

    October 31, 2024 at 12:16 pm in reply to: marker.numKeys works sometimes, sometimes not

    Yeah! After Effects’ keyframe indices start at 1. This means the first keyframe is key(1), the second is key(2), and so on !

  • Hey Hiro! I finaly got to test the expression and it wasn’t working so here’s a working one with the right steps:

    1. Make a null object and link you camera to it.
    2. add a dropdown menu and two sliders
    3. paste this expression in the position:

    // Retrieve the selected direction and duration

    var direction = effect("Direction")(1).value;

    var duration = effect("Duration")(1).value;

    var distance = effect("Distance")(1).value;

    // Define movement parameters

    var startPos = [0, 0]; // Starting position (relative to current position)

    var endPos;

    // Determine end position based on selected direction

    switch (direction) {

    case 1: // Bottom to Top

    endPos = [0, -distance];

    break;

    case 2: // Top to Bottom

    endPos = [0, distance];

    break;

    case 3: // Left to Right

    endPos = [distance, 0];

    break;

    case 4: // Right to Left

    endPos = [-distance, 0];

    break;

    default:

    endPos = [0, 0];

    }

    // Determine current position using linear interpolation

    if (time < duration) {

    // Moving from startPos to endPos

    ease(time, 0, duration, startPos, endPos);

    } else {

    // After duration, stay at endPos

    endPos;

    }


    Here’s a screenshot of how it looks for me.

Page 2 of 9

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