Represents a vector that is used to encode three-dimensional physical rotations.
public value class Quaternion : IEquatable<System::Numerics::Quaternion>
public struct Quaternion : IEquatable<System.Numerics.Quaternion>
type Quaternion = struct
Public Structure Quaternion
Implements IEquatable(Of Quaternion)
The Quaternion structure is used to efficiently rotate an object about the (x,y,z) vector by the angle theta, where:
w = cos(theta/2)
Constructors Fields W
The rotation component of the quaternion.
XThe X value of the vector component of the quaternion.
YThe Y value of the vector component of the quaternion.
ZThe Z value of the vector component of the quaternion.
Properties IdentityGets a quaternion that represents no rotation.
IsIdentityGets a value that indicates whether the current instance is the identity quaternion.
Item[Int32]Gets or sets the element at the specified index.
ZeroGets a quaternion that represents a zero.
Methods Add(Quaternion, Quaternion)Adds each element in one quaternion with its corresponding element in a second quaternion.
Concatenate(Quaternion, Quaternion)Concatenates two quaternions.
Conjugate(Quaternion)Returns the conjugate of a specified quaternion.
Create(Single, Single, Single, Single) Create(Vector3, Single) CreateFromAxisAngle(Vector3, Single)Creates a quaternion from a unit vector and an angle to rotate around the vector.
CreateFromRotationMatrix(Matrix4x4)Creates a quaternion from the specified rotation matrix.
CreateFromYawPitchRoll(Single, Single, Single)Creates a new quaternion from the given yaw, pitch, and roll.
Divide(Quaternion, Quaternion)Divides one quaternion by a second quaternion.
Dot(Quaternion, Quaternion)Calculates the dot product of two quaternions.
Equals(Object)Returns a value that indicates whether this instance and a specified object are equal.
Equals(Quaternion)Returns a value that indicates whether this instance and another quaternion are equal.
GetHashCode()Returns the hash code for this instance.
Inverse(Quaternion)Returns the inverse of a quaternion.
Length()Calculates the length of the quaternion.
LengthSquared()Calculates the squared length of the quaternion.
Lerp(Quaternion, Quaternion, Single)Performs a linear interpolation between two quaternions based on a value that specifies the weighting of the second quaternion.
Multiply(Quaternion, Quaternion)Returns the quaternion that results from multiplying two quaternions together.
Multiply(Quaternion, Single)Returns the quaternion that results from scaling all the components of a specified quaternion by a scalar factor.
Negate(Quaternion)Reverses the sign of each component of the quaternion.
Normalize(Quaternion)Divides each component of a specified Quaternion by its length.
Slerp(Quaternion, Quaternion, Single)Interpolates between two quaternions, using spherical linear interpolation.
Subtract(Quaternion, Quaternion)Subtracts each element in a second quaternion from its corresponding element in a first quaternion.
ToString()Returns a string that represents this quaternion.
Operators Extension MethodsCollaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide. In this articleWas this page helpful?
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4