Quaternion Structure |
Namespace: LightBuzz
The Quaternion type exposes the following members.
| Name | Description | |
|---|---|---|
| Quaternion(Vector3D, Single) |
Construct a new Quaternion from vector and w components
| |
| Quaternion(Single, Single, Single, Single) |
Constructs a new quaternion with given X, Y, Z, and W components.
|
| Name | Description | |
|---|---|---|
| EulerAngles | Returns the euler angle representation of the rotation. | |
| Item |
Access the X, Y, Z, W components of the quaternion using [0], [1], [2], [3] respectively.
| |
| Length |
Returns the length of the current vector.
| |
| LengthSquared |
Returns the squared length of the current vector.
| |
| Magnitude |
Returns the length of the current vector.
| |
| MagnitudeSquared |
Returns the squared length of the current vector.
| |
| Normalized |
Scale the given quaternion to unit length
| |
| XYZ |
Returns the 3D vector (X, Y, and Z values) of the current quaternion.
|
| Name | Description | |
|---|---|---|
| Angle |
Returns the angle (in degrees) between two quaternions.
| |
| AngleAxis |
Creates a rotation which rotates the specified angle degrees around the specified axis.
| |
| Dot |
Returns the dot product of two quaternions.
| |
| Equals(Object) |
Determines whether the specified object is equal to the current object.
(Overrides ValueTypeEquals(Object).) | |
| Equals(Quaternion, Quaternion) |
Specifies whether two quaternions are approximately equal.
| |
| Euler(Vector3D) |
Returns a rotation that rotates Z degrees around the Z axis, X degrees around the X axis, and Y degrees around the Y axis (in that order).
| |
| Euler(Single, Single, Single) | Returns a rotation that rotates Z degrees around the Z axis, X degrees around the X axis, and Y degrees around the Y axis (in that order). | |
| FromToRotation |
Creates a rotation which rotates from towards to.
| |
| GetHashCode |
Returns the hash code of the current object.
(Overrides ValueTypeGetHashCode.) | |
| GetType | (Inherited from Object.) | |
| Inverse |
Returns the inverse of rotation.
| |
| Lerp |
Linearly interpolates between two quaternions by t.
| |
| LookRotation(Vector3D) |
Creates a rotation with the specified forward and upwards directions.
| |
| LookRotation(Vector3D, Vector3D) |
Creates a rotation with the specified forward and upwards directions.
| |
| Multiply(Quaternion, Quaternion) |
Multiplies a vector with another vector.
| |
| Multiply(Quaternion, Vector2D) |
Multiplies the given rotation around the given point.
| |
| Multiply(Quaternion, Vector3D) |
Multiplies the given rotation around the given point.
| |
| Negate |
Negates every component of the specified quaternion.
| |
| Normalize |
Makes the current vector have a magnitude of 1.
| |
| Normalize(Quaternion) |
Makes the specified quaternion have a magnitude of 1.
| |
| Rotate |
Rotates the current quaternion according to the specified 3D vector.
| |
| RotateTowards |
Rotates a rotation which rotates from towards to.
| |
| Set |
Sets the X, Y, Z, and W components of the current quaternion.
| |
| Slerp |
Spherically interpolates between two quaternions by t.
| |
| SlerpUnclamped |
Spherically interpolates between two quaternions by t. The parameter t is not calmped.
| |
| ToString |
Returns a string representation of the current object.
(Overrides ValueTypeToString.) |
| Name | Description | |
|---|---|---|
| Equality |
Compares two quaternions for equality.
| |
| (Quaternion to Quaternion) |
Converts the specified Unity Quaternion into its equivalent quaternion.
| |
| (Quaternion to Quaternion) |
Converts the specified Quaternion into its equivalent Unity Quaternion.
| |
| Inequality |
Compares two quaternions for inequality.
| |
| Multiply(Quaternion, Quaternion) |
Multiplies a quaternion by another one.
| |
| Multiply(Quaternion, Vector2D) |
Multiplies a quaternion by a 2D point.
| |
| Multiply(Quaternion, Vector3D) |
Multiplies a quaternion by a 3D point.
| |
| Multiply(Quaternion, Vector3) |
Multiplies the quaternion with a Unity 3D point.
|
| Name | Description | |
|---|---|---|
| Identity |
The identity rotation.
| |
| W |
W component of the vector.
| |
| X |
X component of the vector.
| |
| Y |
Y component of the vector.
| |
| Z |
Z component of the vector.
|