Page 1 of 1

Tracking a parented layer

Posted: December 10th, 2008, 3:47 pm
by raydnz
Hi. Kinda new to expressions in AE so this is well over my head... i want the 3D camera to track a layer which is parented to another animated layer (ie Parent layer is animated thru 3D space, child layer is spinning around the parent (an old 3D trick to fake handheld motion). However i can't just link the camera POI to the target layer obviously so i need to return the child layers world position... where do i begin?
Thanks
R

Re: Tracking a parented layer

Posted: December 10th, 2008, 4:14 pm
by Dan Ebberts
Try this expression for the POI:

L = thisComp.layer("Your Child Layer's Name");
L.toWorld(L.anchorPoint)


Dan

Re: Tracking a parented layer

Posted: December 11th, 2008, 12:03 pm
by raydnz
Thanks for that, Dan. I'll give it a shot...

Re: Tracking a parented layer

Posted: December 11th, 2008, 3:53 pm
by hype
You could also use TrackerViz for this. Just select the child layer, pick Track Combine from TrackerViz's drop down menu, set it to keyframes, and run it. It will make a new little solid that is entirely independent and has keyframes of the child layer's position.

I'm sure Dan's expression works awesome, just posting this as another option, or something to think of in the future. :)