ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Find global 3D position of a parented null

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Richard Frazer
Find global 3D position of a parented null
on Mar 20, 2010 at 3:25:58 pm

Im trying to calculate the true 3D coordinates of a Null object in world space. Thing is, it's parented to another 3d object, so its actual "position" value that I can reference with an expression remains unchanged throughout the animation. The parent object is moving around and doing all kinds of rotations (and I dont want to have to work out some trig-based script to take the parent's position / rotation and offset the position of the Null etc). Is there some function that can do this?
In case I havent explained this very well, lets imagine the Null object is at [100, 100, 100] in 3D space at the start of the animation. I link it to a parent object that has a position of [640,360,0]. The "position" value displayed by the Null now becomes [-540,-260,100] (i.e it's now relative to it's parent, rather than the world space). I then rotate the parent object 180 degrees along the Y axis. The Null still displays [-540,-260,100] as it's position, despite having moved to the other side of the Composition. If I remove the link to the parent it now displays its "true" 3D position of [1180,100,-100] - this is the value Im trying to access via an expression.


Return to posts index

Erik Waluska
Re: Find global 3D position of a parented null
on Mar 20, 2010 at 4:44:51 pm

Carl Larsen did a couple of really good tutorials on this subject that might be just what you're looking for:

Child Tracking 1
http://library.creativecow.net/articles/larsen_carl/child_tracking.php

Child Tracking 2
http://library.creativecow.net/articles/larsen_carl/child_tracking2.php



Return to posts index

Richard Frazer
Re: Find global 3D position of a parented null
on Mar 20, 2010 at 5:07:33 pm

Perfect! Thanks a lot.



Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]