D3DXQuaternionExp function (D3DX10Math.h)

Note

The D3DX10 utility library is deprecated. We recommend that you use DirectXMath instead.

Calculates the exponential.

Syntax

D3DXQUATERNION* D3DXQuaternionExp(
  _Inout_       D3DXQUATERNION *pOut,
  _In_    const D3DXQUATERNION *pQ
);

Parameters

pOut [in, out]

Type: D3DXQUATERNION*

Pointer to the D3DXQUATERNION that is the result of the operation.

pQ [in]

Type: const D3DXQUATERNION*

Pointer to the source D3DXQUATERNION structure.

Return value

Type: D3DXQUATERNION*

Pointer to a D3DXQUATERNION structure that is the exponential.

Remarks

This method converts a pure quaternion to a unit quaternion. D3DXQuaternionExp expects a pure quaternion, where w is ignored in the calculation (w == 0).

Given a pure quaternion defined by:
q = (0, theta * v);

This method calculates the exponential result.
exp(Q) = (cos(theta), sin(theta) * v)

where v is the vector portion of a quaternion.

The return value for this function is the same value returned in the pOut parameter. In this way, the D3DXQuaternionExp function can be used as a parameter for another function.

The D3DXQuaternionSquadSetup method can also be used to set up the control points of a quaternion.

Use D3DXQuaternionNormalize for any quaternion input that is not already normalized.

Requirements

Requirement Value
Header
D3DX10Math.h
Library
D3DX10.lib

See also

Math Functions