| 600 | } |
| 601 | |
| 602 | void xQuatFromAxisAngle(xQuat* q, const xVec3* a, F32 t) |
| 603 | { |
| 604 | F32 t_2; |
| 605 | |
| 606 | if (t == 0.0f) |
| 607 | { |
| 608 | xQuatCopy(q, &g_IQ); |
| 609 | } |
| 610 | else |
| 611 | { |
| 612 | t_2 = isin(t * 0.5f); |
| 613 | q->s = icos((t * 0.5f)); |
| 614 | xVec3SMul(&q->v, a, t_2); |
| 615 | } |
| 616 | } |
| 617 | |
| 618 | void xQuatToMat(const xQuat* q, xMat3x3* m) |
| 619 | { |