Copy link to clipboard
Copied
I want the background to move with the camera but at a reduce positioning, say 25% of the normal movements. Can this be done?
Thanks for an answers, using AE 7
Oops. Sorry, I didn't copy and paste the whole thing. This should be better:
P = thisComp.activeCamera.transform.position;
value + (P - P.valueAtTime(0))*0.25
Dan
Copy link to clipboard
Copied
Probably something like this:
thisComp.activeCamera.transform.position;
value + (P - P.valueAtTime(0))*0.25
Dan
Copy link to clipboard
Copied
Thanks Dan, although I am getting an error when I place it on the position of the layer I only want to move 25%.
I get the error 'AE warning: Class 'Layer' has no property named 'P' Expression disabled.'
Have I done something wrong?
Cheers
Copy link to clipboard
Copied
Oops. Sorry, I didn't copy and paste the whole thing. This should be better:
P = thisComp.activeCamera.transform.position;
value + (P - P.valueAtTime(0))*0.25
Dan
Copy link to clipboard
Copied
Thanks Dan, now no errors, but the layer doesn't seem to slow down at all compared to the background. The expression is placed in the Position property of the layer and the camera parented to a null still makes the layer move at 100%.I have attached the file if you could help me on this.
S
Copy link to clipboard
Copied
Thanks Dan.
Copy link to clipboard
Copied
Thanks Dan, no errors now but I have placed the expression on the layer's Postion property and the camera still sees the layer go at 100% compared to the background.
S
Copy link to clipboard
Copied
Ah, if the camera has a parent, this should work better:
C = thisComp.activeCamera;
p0 = C.toWorld([0,0,0],0);
p1 = C.toWorld([0,0,0],time)
value + (p1 - p0)*0.25
Note that you won't see any movement until you animate the camera position over time.
Dan
Copy link to clipboard
Copied
Excellent, both answers were great, didn't realise you had to play the timeline, thanks loads!!!
Copy link to clipboard
Copied
I need to have the same proportion of movements in the rotate properties, what code do you need for this?
Cheers