mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-16 00:54:54 +00:00
Updated normalize()
It seems normalize() already changes the quaternion so the asignation is not needed.
This commit is contained in:
parent
3630f97ab1
commit
1733ecc315
1 changed files with 2 additions and 3 deletions
|
|
@ -229,11 +229,10 @@ inline F32 QuatF::angleBetween( const QuatF & q )
|
||||||
{
|
{
|
||||||
// angle between two quaternions
|
// angle between two quaternions
|
||||||
QuatF base(x,y,z,w);
|
QuatF base(x,y,z,w);
|
||||||
base=base.normalize();
|
base.normalize();
|
||||||
QuatF q_norm=q;
|
QuatF q_norm=q;
|
||||||
q_norm=q_norm.normalize();
|
q_norm.normalize();
|
||||||
return 2.0f*mAcos(base.dot(q_norm));
|
return 2.0f*mAcos(base.dot(q_norm));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endif // _MQUAT_H_
|
#endif // _MQUAT_H_
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue