0
$\begingroup$

There is no Quaternion in Copy Rotation's Order option:

enter image description here

What happens when the owner of the constraint has quaternion rotation mode? What if the target has quaternion rotation mode too? How can I only copy an axis of quaternion rotation?

$\endgroup$

3 Answers 3

0
$\begingroup$

You can't use a copy rotation constraint to copy rotation as a quaternion. With the way that the constraint works, that wouldn't make much sense. Fortunately, mostly, you don't need to.

Any 3D angle can be expressed in multiple ways-- as a quaternion, as an axis-angle rotation, or as any of your 6 kinds of Eulers. That means that a quaternion angle can be read as an Euler angle, and an Euler angle can be read as a quaternion angle. So the transformation mode of your source and destination doesn't really matter for purposes of the constraint.

The order used by the constraint matters in a few situations. One situation is that you're using an influence less than 1.0. For these situations, the constraint reads the source and destination angles, in whatever order you've specified, multiplies the source angle triplets by the influence, and then feeds those into the destination angles (in a way that depends on mode: default just replaces those destination angles.) Another situation would be that you're not on replace mode, in which case the source angles might be added to the destination angles. In either case, following this constraint, the angle is not recomputed into either quaternion or Euler representation, but as a 4x4 matrix that represents the complete orientation (including scale, location, and rotation irrespective of rotation mode in that matrix.)

The idea of copying a single quaternion axis isn't really one that makes sense. Quaternions are not divisible into axes. They are complete, 4D vectors that represent angles.

You might find it useful to play around with using drivers to edit your angles instead. Drivers can be used to control the individual components (not axes) of quaternions, copying those components from a different transformation, if that's what you want. This might be a useful way to understand how quaternions don't have multiple axes the same way that Euler angles do. However, based on what you're saying, it's unlikely to get you to the animation you want.

$\endgroup$
-1
$\begingroup$

That field is order not rotation mode and for quaternions you simply don't need any orders.

the default state works for both quaternions and angle-axis rotations.

$\endgroup$
2
  • $\begingroup$ What's the difference between rotation mode and order? I think rotation mode like XYZ is just the order of rotation axis? Plus the result does change when I use different order, even both owner and target use quaternion rotation mode. $\endgroup$ Sep 28, 2021 at 15:41
  • $\begingroup$ @LaiYu-Hsuan yes, it is the order of rot-axes. rotation order is something which is needed just for "Euler rotation". Quaternions are different kind of mathematical objects (see wiki) and have nothing to do with this order so you should use the default mode. $\endgroup$ Sep 28, 2021 at 15:46
-1
$\begingroup$

This is my understanding so far (probably not entirely correct):

The Order option is indeed rotation mode. (The answer above is wrong). Copy Rotation converts the quaternion to euler, then converts it back. It's impossible to only copy one of 4 quaternion values (and even you could, the result would be very counterintuitive). And because the relationship between quaternion and euler is not a 1-to-1 mapping, this conversion can lead to unexpected result when used with keyframe interpolation.

$\endgroup$
4
  • $\begingroup$ The Order is just what we need in euler rotations. Quaternion and Angle-axis rotations have nothing to do with order. the internal process is done by Transformation Matrices not any other sort of conversions. the conversion itself is not one2one but because the process would be done in all frames, no weird behaviour occurs. $\endgroup$ Sep 29, 2021 at 10:39
  • $\begingroup$ quaternions are different mathematical objects and x,y,z,w has nothing to do with rotation axis in euler. see en.wikipedia.org/wiki/Quaternion $\endgroup$ Sep 29, 2021 at 10:40
  • $\begingroup$ each rotation mode is animated differently in different channels. so x in quaternions is not the x in euler rotations. but x,y,z channels in euler Orders are shared. $\endgroup$ Sep 29, 2021 at 10:44
  • $\begingroup$ I understand what quaternion is. And Copy Rotation converts quaternion to Euler first. PERIOD. I literally checked the Blender source code and it does call mat4_to_compatible_eulO. $\endgroup$ Sep 29, 2021 at 18:10

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.