From: frohlich Date: Fri, 27 Feb 2009 05:16:52 +0000 (+0000) Subject: Fix problem in unit quaternion return. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=8e5e65734478a5bd4058f3d9828edd371309570e;p=simgear.git Fix problem in unit quaternion return. Modified Files: SGQuat.hxx --- diff --git a/simgear/math/SGQuat.hxx b/simgear/math/SGQuat.hxx index bb607885..1f6aaef0 100644 --- a/simgear/math/SGQuat.hxx +++ b/simgear/math/SGQuat.hxx @@ -213,7 +213,7 @@ public: { T nAxis = norm(axis); if (nAxis <= SGLimits::min()) - return SGQuat(1, 0, 0, 0); + return SGQuat::unit(); T angle2 = 0.5*nAxis; return fromRealImag(cos(angle2), T(sin(angle2)/nAxis)*axis); }