-
Wiggling the result of an expression
I have a series of photos arranged in 3D space, and I have a NULL which moves amoungst these.
I have used an expression on a camera position to follow the NULL which looks like this:
X = 1100 – (thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.3)[0] * 0.3);
Y = 800 – (thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.3)[1] * 0.3);
Z = thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.1)[2] – 600;
[X,Y,Z];This works fine, but now I would like to add a wiggle to my position, I tried this:
X = 1100 – (thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.3)[0] * 0.3);
Y = 800 – (thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.3)[1] * 0.3);
Z = thisComp.layer(“Null 1”).transform.position.valueAtTime(time – 0.1)[2] – 600;
[X,Y,Z];
wiggle(0.5,40);But this doesn’t work, it wiggles, but no longer follows my NULL.
I know I could wiggle my NULL but I am using that also as a reference to the focus point in depth of field, so if the NULL were to move away from the picture it would become out of focus.
What am I missing here?
Thanks
Matt