Copy link to clipboard
Copied
Hi community.
Recently Rick Gerard provided me with an expression using create nulls with paths, to move with 1 pixel increments using Null paths.
rNull = thisComp.layer("Null Left");
strtPos = rNull.position;
endX = 126
,
spd = 1
; // number of pixels to move per frame
StrtTime = 0; // Start on Frame 40;
eTime = endX/spd;
t = timeToFrames();
mov = linear(t, StrtTime, StrtTime + eTime, 0, endX);
[strtPos[0] + mov, strtPos[1]];
This animation below is correct. And is using the right null
For the following animation below, I changed the expression into the left null (deleting the code from the right null), so the green line is going in reverse, which is correct, but when it starts to expand from the centre of the line towards the right side, the line is cut short, not an even animation. (Not enough frames im dont know....) . see Example below:
My thoughts to emulate the blue line animation would be, having 2 different expressions I can use with Ricks code in the position. .
One line going from left to middle
Another line going from middle to right
And I can join them, unless its possible to have one expression emulating the blue line animation, which is called a bipolar line behavior.
Thanks for your help.
Have something to add?