2
$\begingroup$

Object1 is a child of Object2. I rotated Object2 thus rotating Object1. In the Transform section of the N panel Rotation values of Object1 are 0,0,0. How do I get global values of rotation of Object1 related to world?

This may seem trivial when you have only 2 objects, but actually I have a chain of child-parent relations, each one rotated by some degree. Calculating this by hand would take ages.

I need to align rotation of the object that is not part of this child-parent chain with the object that is.

child rotation

$\endgroup$
  • $\begingroup$ Could you add an image that describes the situation with parented objects and the independent one you want to align? The transformation of a child to parent is stored in the child object's matrix_parent_inverse see: blender.stackexchange.com/questions/3763/… $\endgroup$ – stacker Mar 1 '15 at 12:23
  • $\begingroup$ I added the image, I'd prefer to avoid Python scripting if possible. $\endgroup$ – jubi Mar 1 '15 at 14:49
3
$\begingroup$
  1. Add a Copy Rotation constraint to the object you want to rotate. In constraint panel, set Target to that child object;
  2. After seeing it being aligned well, CtrlA > Visual Transform;
  3. Delete that constraint, since you don't need it anymore.

Edit:

If you just want to "know" the global rotation info, you can simply AltP > Clear and Keep Transformation, then you will see the visual rotation applied, which is the global rotation. After getting what you want, you can simply CtrlZ to undo.

$\endgroup$
  • $\begingroup$ After your suggestion, I (finally) updated the gif in my answer. $\endgroup$ – David Mar 1 '15 at 20:01
  • $\begingroup$ @David LOL cool! things now become more convincable. :D $\endgroup$ – Leon Cheung Mar 2 '15 at 3:31
  • $\begingroup$ "Clear and Keep Transformation" seems the simplest solution to me, I actually stumbled upon it today and came here to update my answer and found your edit, thanks :) $\endgroup$ – jubi Mar 2 '15 at 10:44
2
$\begingroup$

I found a dirty workaround, maybe someone will find a cleaner solution:

Select rotated child object that you would like to align to. Press Shift-Numpad 1 to align view to the object. Press Ctrl-Alt-Numpad 0 to align camera to view.

Now your camera's Transform Rotation data are equal to global rotation of your child object.

  • Select object you would like to align.
  • Shift select your camera.
  • Go to object tab.
  • Hover your mouse over rotation values, press right mouse button, select "Copy to selected".

Voila, your object has the desired global rotation values.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.