Copy link to clipboard
Copied
Hi,
I wrote preset with expressions in AE cs4 and it was calculating the direction of layer's motion.
It worked perfectly in CS4.
In CS5 the resulting vector very often has a length of 0 - especially with Nulls that have tracking data applied.
Even though the Null IS moving around.
One workaround I found was to use a BakeTransforms script on the Null layer.
The motion doesn't change, but now for some reason position.vector gives a proper value.
After some testing it seems that if a Null gets tracking data applied, the position.velocity vector for that null is always invalid
Any ideas?
>this totally worked in CS4 so what gives?
Really? For me it's the same in CS4 and CS5.
One other thing you can do is change the spatial interpolation of the keyframes to Bezier.
Dan
Copy link to clipboard
Copied
Instead of transform.position.velocity, try transform.position.velocityAtTime(time-.001)
Dan
Copy link to clipboard
Copied
Thanks, it worked but now I have a problem with border frames
(first or last) as with sampling at slightly different time ends up with no motion next to one of them .
I did a workaround by changing the time delta for this trick dependant on the time value but still it's not full proof.
Any idea why velocity at the exact frame time gives a zero vector?
The speed value is correct so there is motion in these frames (it's not an issue of frame easing)
And again - this totally worked in CS4 so what gives?
Copy link to clipboard
Copied
>this totally worked in CS4 so what gives?
Really? For me it's the same in CS4 and CS5.
One other thing you can do is change the spatial interpolation of the keyframes to Bezier.
Dan
Copy link to clipboard
Copied
Jackpot
That's what I needed, totally forgot that position has two different easing modes (temporal and spatial).
But still I'm totally positive I didn't have to do it in CS4 - probably the tracker was changed or something
Find more inspiration, events, and resources on the new Adobe Community
Explore Now