This commit is contained in:
Antonis Geralis 2024-05-07 00:20:04 +03:00 committed by GitHub
parent e56af392ad
commit 747dbd3529
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2366,14 +2366,13 @@ RMAPI Quaternion QuaternionFromAxisAngle(Vector3 axis, float angle)
{ {
angle *= 0.5f; angle *= 0.5f;
float lengthSq = 0.0f; float length = 0.0f;
float ilength = 0.0f; float ilength = 0.0f;
// Vector3Normalize(axis) // Vector3Normalize(axis)
length = axisLength; length = axisLength;
if (length == 0.0f) length = 1.0f; if (length == 0.0f) length = 1.0f;
ilength = 1.0f/length; ilength = 1.0f/length;
axis.x *= ilength; axis.x *= ilength;
axis.y *= ilength; axis.y *= ilength;
axis.z *= ilength; axis.z *= ilength;