Page 1 of 1


Posted: October 4th, 2011, 2:46 am
by atropper
Hi there,
Im using this script on a psd file i imported:

cam = this_comp.active_camera;
distance = length(sub(position , cam.position));
s = distance / cam.zoom;
mul(scale, s)

it should maintain the layer size in the comp no matter where i put it in z position. Not working for me: should i apply it to the layer position or scale property?

Anyone who knows that script can give me some pointers?


Re: Cam-Distance

Posted: October 14th, 2011, 12:04 pm
by kobyg
Hi atropper,
I hope this is still relevant for you...

This expression works fine for me!
You should give this expression to the Scale propery.

Make also sure you have:
1. a camera in the comp
2. your layer (the one you've given this expression to) is a 3D layer.
4. you are viewing the comp through the Active Camera (and not tny Custom View or Front camera)