ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

control slider keyframe with MARKER

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Ehsan Adham
control slider keyframe with MARKER
on Nov 28, 2019 at 8:07:08 pm
Last Edited By Ehsan Adham on Nov 28, 2019 at 8:10:35 pm

Hi Every one

i have one null layer, it have slider control and it have two keyframe,

how can i control this keyframes with layer marker?



Return to posts index

Andrei Popa
Re: control slider keyframe with MARKER
on Nov 29, 2019 at 6:45:28 am

If you plan to use it like this, you don't even need keyframes. This expression will take the values from the markers comments. Just make sure the comments are always a number.

v1 = parseInt(marker.key(1).comment);
v2 = parseInt(marker.key(2).comment);
t1 = marker.key(1).time;
t2 = marker.key(2).time;
(isNaN(v1+v2)) ? value : linear(time,t1,t2,v1,v2);


Andrei
My Envato portfolio.


Return to posts index

Ehsan Adham
Re: control slider keyframe with MARKER
on Nov 29, 2019 at 12:01:42 pm

Taaaaanks Andrei

Now i have two Question:

1. how can i use this two MARKER like toggle hold keyframe ?
2. i want name this MARKERS to for example clip1, clip2. How can i control the value of MARKERS?

Again Tanks My Friend


Return to posts index


Andrei Popa
Re: control slider keyframe with MARKER
on Nov 29, 2019 at 12:17:27 pm

What do you mean use them like toggle hold keyframe? To have the slider the value of first keyframe until it reaches the second and then snap to that value?

And if you want to rename the markers as you please, you can re-create those 2 keyframes and add this expression instead. The values are now taken from the keyframes.


v1 = valueAtTime(key(1).time);
v2 = valueAtTime(key(2).time);
t1 = marker.key(1).time;
t2 = marker.key(2).time;
(isNaN(v1+v2)) ? value : linear(time,t1,t2,v1,v2);


Andrei
My Envato portfolio.


Return to posts index

Ehsan Adham
Re: control slider keyframe with MARKER
on Nov 29, 2019 at 1:25:02 pm

OH MU GOD
TAAAAAAAAANKS ANDREI

YES, My mean: For Example Marker "clip1" value is 150 in time 00:01. So i want go to time 00:02 and Marker "clip2". Now Value should be 200. i don't want that value be changed between two marker.
Like Toggle Hold Keyframe.

Many Tanks My Friend


Return to posts index

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