Quaternion: replace conversion in rotate() with AxisAngle call

This commit is contained in:
Matthias Grob
2017-10-17 17:37:23 +02:00
parent b241cf5c95
commit ee2219b836
+2 -4
View File
@@ -330,14 +330,12 @@ public:
/** /**
* Rotate quaternion from rotation vector * Rotate quaternion from rotation vector
* TODO replace with AxisAngle call
* *
* @param vec rotation vector * @param vec rotation vector
*/ */
void rotate(const Vector<Type, 3> &vec) void rotate(const AxisAngle<Type> &vec)
{ {
Quaternion res; Quaternion res(vec);
res.from_axis_angle(vec);
(*this) = res * (*this); (*this) = res * (*this);
} }