I tried your expression and found 2 flaws to it. It said that K1 is a function and it needed a number on line 22, and got out of reach for either markers or layers. So i modified it a bit. Tell me if it works, or what does’nt work, in case something is wrong. This is what i got
n= 0;
if (marker.numKeys > 0){
n = marker.nearestKey(time).index;
if (marker.key(n).time > time){
n--;
}
};
prev = n;
next = (n>=marker.numKeys) ? marker.numKeys : (n+1);
K1 = prev;
K2 =next;
Val1 = thisComp.layer("val "+prev.toString()).text.sourceText;
Val2 = thisComp.layer("val "+next.toString()).text.sourceText;
T1 = parseInt(Val1.split(' '));
T2 = parseInt(Val2.split(' '));
U = marker.key(K1).time;
B = marker.key(K2).time;
TT = ease(time, U, B, T1, T2);
[TT, TT]
Andrei
My Envato portfolio.