Position Rotation - of parent
-
On 17/01/2014 at 02:51, xxxxxxxx wrote:
Hi
I try to Position Objects on a spline and have some issues when the spline is not in the same null object- i try to get the offset by checking all - parent objects - but i have to mention the rotation - have one of you an idea ?
def GetContainerPosOffset(self, node) : parentpos = c4d.Vector(0) if node.GetUp() != None: parnode = self.GetContainerPosOffset(node.GetUp()) #print parnode parentpos += parnode parentpos += node.GetAbsPos() return parentpos
Edit notice NiklasR : fixed code formatting
-
On 17/01/2014 at 02:59, xxxxxxxx wrote:
You should prefer GetMg().off over GetAbsPos(). Why not just use GetUpMg()?
Best,
-Niklas -
On 17/01/2014 at 03:19, xxxxxxxx wrote:
hey Niklas,
thanks for your reply -
your right - it's a better way - but it don`t help me to calculate the right position
-
On 17/01/2014 at 03:23, xxxxxxxx wrote:
a nice way to get the world coordinates of a object
-
On 17/01/2014 at 03:35, xxxxxxxx wrote:
sorry
your right - i red the description of the function -