ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Time Remap between Animation (but not based on Keyframes)

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Helmut Kunze
Time Remap between Animation (but not based on Keyframes)
on Jul 11, 2018 at 3:32:23 pm

Hello Folks,

Love this forum and it helped me a lot in the past months.

My problem:

I prepare a essential Graphic with an In-animation (2 sec) and an Out-animation (2 sec)
I have a slider to control the time but it is messing up my animation time.
The expression is passed on this tutorial (https://www.youtube.com/watch?v=ThyrPqzSO8o)
FluxVFX After Effects Templates

But it does not free the first and last two seconds of my animation from time remapping.
It should be 0:00:02:00 instead of 0:00:03:05.
I'm not the smart with expressions.
Could someone help me out here?


duration=effect("Duration")("Slider");
a=linear(time, startTime, startTime+2, 0, 2);
b=linear(time, startTime+duration , startTime+duration-2, 8, 10);

linear(time, inPoint, duration, a, b);


Return to posts index

Kalleheikki Kannisto
Re: Time Remap between Animation (but not based on Keyframes)
on Jul 12, 2018 at 3:33:48 pm

It seems that this is the same exact issue as here:

https://www.videocopilot.net/forum/viewtopic.php?f=5&t=129541

Kalleheikki Kannisto
Senior Graphic Designer


Return to posts index

Helmut Kunze
Re: Time Remap between Animation (but not based on Keyframes)
on Jul 12, 2018 at 3:38:18 pm

Hey,
Thanks for the Link.
I found a solution with this tutorial the last hour:






Works great if you want ultimate control about your timings in Premiere Pro.

I posted the code from my project for everyone, with a similar problem 😉

I'm new here.
Can i close that post as answered?

var fps = 1/thisComp.frameDuration;

var lt = thisComp.layer("Controls").effect("Duration")(1)*fps;
var li = thisComp.layer("Controls").effect("InPoint")(1)*fps;
var lo = thisComp.layer("Controls").effect("OutPoint")(1)*fps;

var m1 = 0;
var m2 = framesToTime(li);
var m3 = framesToTime(lt - lo);
var m4 = framesToTime(lt);

var k1 = 0;
var k2 = framesToTime(50);
var k3 = framesToTime(200);
var k4 = framesToTime(250);

if (time &lt; m2) {
linear (time, m1, m2, k1, k2);
} else if (time &lt; m3) {
linear (time, m2, m3, k2, k2);
} else {
linear (time, m3, m4, k3, k4);
}


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]