3dmath.cpp File Reference
Detailed Description
implementation for 3dmath classes
- Version:
- 0.1
- Date:
- 15/06/99
Functions | |
| vector | operator * (const vector &v, const real &fact) |
| vector | operator * (const real &fact, const vector &v) |
| vector | Bisect (vector v0, vector v1) |
| returns the unit vector which halves the arc between v0 and v1 | |
| quaternion | operator * (const quaternion &q, const real &fact) |
| quaternion | operator * (const real &fact, const quaternion &q) |
| int | operator== (const quaternion &q1, const quaternion &q2) |
| int | operator!= (const quaternion &q1, const quaternion &q2) |
| unitquaternion | operator+ (const unitquaternion &q1, const unitquaternion &q2) |
| unitquaternion | operator- (const unitquaternion &q1, const unitquaternion &q2) |
| unitquaternion | operator * (const unitquaternion &q, const real &s) |
| unitquaternion | operator * (const real &s, const unitquaternion &q) |
| unitquaternion | operator/ (const unitquaternion &q, const real &s) |
Variables | |
| const vector | ORIGIN (0, 0, 0) |
| the vector representing the origin | |
| const vector | X_AXIS (1, 0, 0) |
| the unit vector associated to the x axys | |
| const vector | Y_AXIS (0, 1, 0) |
| the unit vector associated to the y axys | |
| const vector | Z_AXIS (0, 0, 1) |
| the unit vector associated to the z axys | |
| const real | G_PI = 3.14159265359 |
| the greek pi constant | |
| const real | G_HALF_PI = 1.570796326795 |
| greek pi / 2 | |
| const real | G_DOUBLE_PI = 6.28318530718 |
| 2 * greek pi | |
Function Documentation
returns the unit vector which halves the arc between v0 and v1
| unitquaternion operator * | ( | const real & | s, | |
| const unitquaternion & | q | |||
| ) |
This function has been defined to trap the use of an operation which is not allowed
| unitquaternion operator * | ( | const unitquaternion & | q, | |
| const real & | s | |||
| ) |
This function has been defined to trap the use of an operation which is not allowed
| quaternion operator * | ( | const real & | fact, | |
| const quaternion & | q | |||
| ) |
This function together with operator*(quaternion,real) implements the commutative product of a scalar by a quaternion
| quaternion operator * | ( | const quaternion & | q, | |
| const real & | fact | |||
| ) |
This function together with operator*(real,quaternion) implements the commutative product of a scalar by a quaternion
This function together with operator*(vector,real) implements the commutative product of a scalar by a vector
This function together with operator*(real,vector) implements the commutative product of a scalar by a vector
| int operator!= | ( | const quaternion & | q1, | |
| const quaternion & | q2 | |||
| ) |
This function check if two quaternions are not equal.
| unitquaternion operator+ | ( | const unitquaternion & | q1, | |
| const unitquaternion & | q2 | |||
| ) |
This function has been defined to trap the use of an operation which is not allowed
| unitquaternion operator- | ( | const unitquaternion & | q1, | |
| const unitquaternion & | q2 | |||
| ) |
This function has been defined to trap the use of an operation which is not allowed
| unitquaternion operator/ | ( | const unitquaternion & | q, | |
| const real & | s | |||
| ) |
This function has been defined to trap the use of an operation which is not allowed
| int operator== | ( | const quaternion & | q1, | |
| const quaternion & | q2 | |||
| ) |
This function check if two quaternions are equal.
Variable Documentation
| const real G_DOUBLE_PI = 6.28318530718 |
2 * greek pi



