Microsoft DirectX 8.1 (Visual Basic)

D3DXQuaternionToAxisAngle

Computes a quaternion's axis and angle of rotation.

D3DXQuaternionToAxisAngle( _ 
    Q As D3DQUATERNION, _ 
    VAxis As D3DVECTOR, _ 
    angle As Single) As Long 

Parameters

Q
The source D3DQUATERNION type.
VAxis
When this function returns, a D3DVECTOR type that identifies the quaternion's axis.
angle
When this function returns, a Single value that identifies the quaternion's angle of rotation, in radians.

Error Codes

If the function fails, an error is raised and Err.Number can be set to one of the following values.

D3DERR_INVALIDCALL
D3DERR_OUTOFVIDEOMEMORY

For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.

Remarks

This function expects unit quaternions.