Anthony Appleyard opened this issue on Jul 22, 2018 · 2 posts
Anthony Appleyard posted Sun, 22 July 2018 at 6:08 AM
A child part is related to its parent by 3 angles, usually called xRotate yRotate zRotate.This method is called Euler angles: https://en.wikipedia.org/wiki/Euler_angles (Here I mean Proper Euler angles, not Tait–Bryan angles.) Sets of these angles must be calculated on the run by solid trigonometry when handling inverse kinematics. Such calculation often does not generate the must suitable value. There are two ways to optimize these values after calculating them:-
(1) As is well known, normalizing the angles X Y Z by adding or subtracting an integer multiple of 360 deg to bring them to between -180 deg and +180 deg.
(2) As may be less well known, changing (X Y Z) to
(-X+180 deg, Y+180 deg, Z+180 deg) (for rotation order zxy or yxz)
( X+180 deg, -Y+180 deg, Z+180 deg) (for rotation order xyz or zyx)
( X+180 deg, Y+180 deg, -Z+180 deg) (for rotation order yzx or xzy)
Both methods leave the child part in the same relation to its parent (but it will affect joint-blending).
(I discovered this relationship by computer search among the 360 * 360 * 360 results of calculating with Euler angles for theta and phi and psi (Poser's x/y/zRotate) = 0 step 1 to 359, when simulating polymer molecules at work, and later proved it by algebra.)