Was doing a tutorial on Quaternions, and couldn’t figure out the order of rotations as the javadoc was a bit off. And I found a few spelling mistakes also, didn’t inspect the whole file, so there may be more.
[patch]
— Base (BASE)
+++ Locally Modified (Based On LOCAL)
@@ -233,7 +233,7 @@
/**
- <code>fromAngles</code> builds a Quaternion from the Euler rotation
-
* angles (x,y,z) aka (pitch, yaw, rall)). Note that we are applying in order: roll, yaw, pitch but<br />
-
* angles (x,y,z) aka (pitch, yaw, roll)). Note that we are applying in order: (y, z, x) aka (yaw, roll, pitch) but<br />
- we’ve ordered them in x, y, and z for convenience.
-
@see <a href="Maths - Conversion Euler to Quaternion - Martin Baker">Maths - Conversion Euler to Quaternion - Martin Baker</a>
*
@@ -489,7 +489,7 @@
/**
- <code>getRotationColumn</code> returns one of three columns specified
- by the parameter. This column is returned as a <code>Vector3f</code>
-
* object. The value is retrieved as if this quaternion was first normalized.<br />
-
* object. The value is retrieved as if this quaternion was first normalized.<br />
*
-
@param i
-
the column to retrieve. Must be between 0 and 2.<br />
@@ -585,7 +585,7 @@
/**
- <code>toAngleAxis</code> sets a given angle and axis to that
- represented by the current quaternion. The values are stored as
-
* following: The axis is provided as a parameter and built by the method,<br />
-
* follows: The axis is provided as a parameter and built by the method,<br />
- the angle is returned as a float.
*
-
@param axisStore
@@ -1096,6 +1096,7 @@
/**
- <code>normalize</code> normalizes the current <code>Quaternion</code>
-
* The result is stored interally.<br />
*/
public Quaternion normalizeLocal() {
float n = FastMath.invSqrt(norm());
@@ -1128,7 +1129,7 @@
/**
- <code>inverse</code> calculates the inverse of this quaternion and
- returns this quaternion after it is calculated. If this quaternion does
-
* not have an inverse (if it's norma is 0 or less), nothing happens<br />
-
* not have an inverse (if it's normal is 0 or less), nothing happens<br />
*
-
@return the inverse of this quaternion
*/
@@ -1158,7 +1159,7 @@
/**
*
- <code>toString</code> creates the string representation of this
-
* <code>Quaternion</code>. The values of the quaternion are displace (x,<br />
-
* <code>Quaternion</code>. The values of the quaternion are displaced by (x,<br />
- y, z, w), in the following manner: <br>
- (x, y, z, w)
*
[/patch]