| VRS - The Virtual Rendering System |
| version 3.3 |
#include <vrs/polar.h>

Public Member Functions | |
| Polar (Vector from=Vector(0, 0, 0), double distance=0, double azimuth=0.0, double altitude=0.0, double twist=0.0) | |
| void | setFrom (Vector from) |
| Vector | getFrom () const |
| void | setDistance (double distance) |
| double | getDistance () const |
| void | setAltitude (double altitude) |
| void | setAzimuth (double azimuth) |
| void | setTwist (double twist) |
| double | getAltitude () const |
| double | getAzimuth () const |
| double | getTwist () const |
| virtual const Matrix & | matrix (Engine *engine=0) const |
| VRS_TYPEINFO (Polar, Transform) | |
| VRS_SERIALIZABLE (Polar) | |
| VRS::Polar::Polar | ( | Vector | from = Vector(0, 0, 0), |
|
| double | distance = 0, |
|||
| double | azimuth = 0.0, |
|||
| double | altitude = 0.0, |
|||
| double | twist = 0.0 | |||
| ) |
3D transformation specified by "polar coordinates", i.e., by altitude, azimuth, and a twist parameter.
| void VRS::Polar::setFrom | ( | Vector | from | ) |
| Vector VRS::Polar::getFrom | ( | ) | const [inline] |
| void VRS::Polar::setDistance | ( | double | distance | ) |
| double VRS::Polar::getDistance | ( | ) | const [inline] |
This matrix can be thought of as having five parts. The first part (the part nearest the point to be transformed) translates the from point to the origin. The last part translates the rotated data back by distance so that the to point is at the origin. Conditions: distance>0.0
| void VRS::Polar::setAltitude | ( | double | altitude | ) |
| void VRS::Polar::setAzimuth | ( | double | azimuth | ) |
| void VRS::Polar::setTwist | ( | double | twist | ) |
| double VRS::Polar::getAltitude | ( | ) | const [inline] |
| double VRS::Polar::getAzimuth | ( | ) | const [inline] |
| double VRS::Polar::getTwist | ( | ) | const [inline] |
The three parts in the middle rotate around the Y axis by azimuth, rotate around the X axis by altitude, and rotate around the Z axis by twist. Angles are given in degrees within the range [0.0, 360.0].
The matrix calculated in this routine is the result of: (trans, -distance)*(twist, Z)*(altitude, X)*(azimuth, Y)* (trans, -from)
Implements VRS::Transform.
| VRS::Polar::VRS_SERIALIZABLE | ( | Polar | ) |