Tested versions
Reproducible in:
System information
Godot v4.3.stable - Debian GNU/Linux trixie/sid trixie - Wayland - Vulkan (Forward+) - dedicated AMD Radeon RX 7600 (RADV NAVI33) - AMD Ryzen 5 7600 6-Core Processor (12 Threads)
Issue description
If one has a model rigged with a Skeleton3D, and changes a bone's rotation by typing values in the temporary Euler inputs, the resultant quaternion will often be non-normalized.
While this appears to work just fine on the skeleton's pose, it will cause an error (and reset of bone rotation) if animation keyframes are played using such a non-normalized quaternion:
AnimationPlayer: 'AnimationPlayer', Animation: '', 3D Rotation Track: 'characterMedium/Root/Skeleton3D:RightUpLeg' contains unnormalized Quaternion key.
The end quaternion (-0.968029, 0.072789, 0.005684, 0.237784) must be normalized.
This also happens if you manually alter the values of the quaternion's inputs. The quaternion ends up non-normalized and fails during animations, but works fine for statically posing the skeleton.
As a possible workaround, if you mouse-drag the euler values (click-hold on the x|y|z label, and drag the mouse left or right to gradually change the values), instead of manually entering values, this seems to cause the resultant quaternion to be normalized.
Though TBH I'm not sure if the issue here should be "editing bone rotation can produce non-normalized quaternions" or "bone animation tracks reject non-normalized quaternions, even though they work for static poses". 😕
Steps to reproduce
The attached MRP includes a rigged model and an AnimationPlayer. The included animation sets the rotation for both legs, but only the left leg works.
You can experiment with ways of changing the rotation value of the RightUpLeg bone, setting its keyframe in the animation, and then seeing if the animation plays.
Minimal reproduction project (MRP)
animate-quaternion.zip
Tested versions
Reproducible in:
System information
Godot v4.3.stable - Debian GNU/Linux trixie/sid trixie - Wayland - Vulkan (Forward+) - dedicated AMD Radeon RX 7600 (RADV NAVI33) - AMD Ryzen 5 7600 6-Core Processor (12 Threads)
Issue description
If one has a model rigged with a
Skeleton3D, and changes a bone's rotation by typing values in the temporary Euler inputs, the resultant quaternion will often be non-normalized.While this appears to work just fine on the skeleton's pose, it will cause an error (and reset of bone rotation) if animation keyframes are played using such a non-normalized quaternion:
This also happens if you manually alter the values of the quaternion's inputs. The quaternion ends up non-normalized and fails during animations, but works fine for statically posing the skeleton.
As a possible workaround, if you mouse-drag the euler values (click-hold on the x|y|z label, and drag the mouse left or right to gradually change the values), instead of manually entering values, this seems to cause the resultant quaternion to be normalized.
Though TBH I'm not sure if the issue here should be "editing bone rotation can produce non-normalized quaternions" or "bone animation tracks reject non-normalized quaternions, even though they work for static poses". 😕
Steps to reproduce
The attached MRP includes a rigged model and an
AnimationPlayer. The included animation sets the rotation for both legs, but only the left leg works.You can experiment with ways of changing the rotation value of the
RightUpLegbone, setting its keyframe in the animation, and then seeing if the animation plays.Minimal reproduction project (MRP)
animate-quaternion.zip