Click or drag to resize
DigitalRuneQuaternionDGetAngle Method
Calculates the angle between two quaternions.

Namespace: DigitalRune.Mathematics.Algebra
Assembly: DigitalRune.Mathematics (in DigitalRune.Mathematics.dll) Version: 1.14.0.0 (1.14.0.14427)
Syntax
public static double GetAngle(
	QuaternionD quaternion1,
	QuaternionD quaternion2
)

Parameters

quaternion1
Type: DigitalRune.Mathematics.AlgebraQuaternionD
The first quaternion.
quaternion2
Type: DigitalRune.Mathematics.AlgebraQuaternionD
The second quaternion.

Return Value

Type: Double
The angle between the given vectors, such that 0 ≤ angle ≤ π.
Remarks

The quaternions are interpreted as orientations. The result is the angle of the quaternion which would rotate an object in the first orientation to the second orientation.

The result is only valid for unit quaternions.

See Also