LIBDSP Version 4.1.9
LIBDSP Software Library
Loading...
Searching...
No Matches
Collaboration diagram for Quaternion to Rotation:

Functions

void tpt_quaternion2rotation_f32 (f32_t *aOutRotations, const f32_t *aInQuater, uint32_t aCount)
 Conversion of quaternion to equivalent rotation matrix.

Detailed Description

Conversions from quaternion to rotation.

Function Documentation

◆ tpt_quaternion2rotation_f32()

void tpt_quaternion2rotation_f32 ( f32_t * aOutRotations,
const f32_t * aInQuater,
uint32_t aCount )

Conversion of quaternion to equivalent rotation matrix.

Parameters
[out]aOutRotationspoints to an array of 3x3 rotations (in row order)
[in]aInQuaterpoints to an array of normalized quaternions
[in]aCountnumber of quaternions
Returns
none
Note
Format of rotation matrix
The quaternion a + ib + jc + kd is converted into rotation matrix:
      a^2 + b^2 - c^2 - d^2                 2bc - 2ad 2bd +
      2ac
                  2bc + 2ad     a^2 - b^2 + c^2 - d^2 2cd -
                  2ab 2bd - 2ac                 2cd + 2ab     a^2 -
b^2 - c^2
                  + d^2
    
Rotation matrix is saved in row order : R00 R01 R02 R10 R11 R12 R20 R21
R22