From 25c5eac5e6ca1035db1eddd7bea9ac78531da57e Mon Sep 17 00:00:00 2001 From: David Thompson Date: Thu, 28 Dec 2023 11:23:49 -0500 Subject: Delete manuals! Good riddance! These are hosted on files.dthompson.us now! --- manuals/sly/Quaternions.html | 185 ------------------------------------------- 1 file changed, 185 deletions(-) delete mode 100644 manuals/sly/Quaternions.html (limited to 'manuals/sly/Quaternions.html') diff --git a/manuals/sly/Quaternions.html b/manuals/sly/Quaternions.html deleted file mode 100644 index bde3992..0000000 --- a/manuals/sly/Quaternions.html +++ /dev/null @@ -1,185 +0,0 @@ - - - - - -Sly: Quaternions - - - - - - - - - - - - - - - - - - - - -
-

-Next: , Previous: , Up: Math   [Contents][Index]

-
-
- -

4.2.5 Quaternions

- -
-
(use-modules (sly math quaternion))
-
- -

Quaternions are used to express rotations about an arbitrary axis in a -way that avoids “gimbal lock” and allows for useful interpolation, -unlike matrices or Euler angles. -

-

Quaternions can be used in rotation transformations -(see Transforms), as well as converted to and from Vectors. -

-
-
Record Type: <quaternion>
-

Data type with 4 fields: w, x, y, z, in -that order. This type descriptor has been exposed for destructuring -via Guile’s (ice-9 match) module. -

- -
-
Scheme Procedure: make-quaternion v theta
-
Scheme Procedure: make-quaternion w x y z
-

Create a new quaternion from an axis angle (a 3D vector v plus -an angle theta) or from individual coordinates w, x, -y, and z. -

- -
-
Scheme Procedure: quaternion v theta
-
Scheme Procedure: quaternion w x y z
-

Alternate spelling of make-quaternion. -

- -
-
Scheme Syntax: quaternion? obj
-

Return #t if obj is a quaternion. -

- -
-
Scheme Syntax: quaternion-w q
-

Return the w coordinate of the quaternion q. -

- -
-
Scheme Syntax: quaternion-x q
-

Return the x coordinate of the quaternion q. -

- -
-
Scheme Syntax: quaternion-y q
-

Return the y coordinate of the quaternion q. -

- -
-
Scheme Syntax: quaternion-z q
-

Return the z coordinate of the quaternion q. -

- -
-
Scheme Variable: identity-quaternion
-

The multiplicative identity quaternion. -

- -
-
Scheme Variable: null-quaternion
-

A quaternion with all fields set to zero. -

- -
-
Scheme Procedure: quaternion* . quaternions
-

Return the product of all quaternions. Return -identity-quaternion if called without arguments. -

- -
-
Scheme Procedure: quaternion-slerp q1 q2 delta
-

Perform a spherical linear interpolation of the quaternions q1 -and q2 and blending factor delta. -

- -
-
Scheme Procedure: quaternion-magnitude q
-

Return the magnitude of the quaternion q. -

- -
-
Scheme Procedure: quaternion-normalize q
-

Return the normalized form of the quaternion q. -

- -
-
Scheme Procedure: vector->quaternion v
-

Convert the 4D vector v to a quaternion. -

- -
-
Scheme Procedure: quaternion->vector q
-

Convert the quaternion q to a 4D vector. -

- -
-
-

-Next: , Previous: , Up: Math   [Contents][Index]

-
- - - - - -- cgit v1.2.3