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

Public Member Functions | |
| VRS_TYPEINFO (GroundPlateNavigation, InteractionTechnique) | |
Static Public Member Functions | |
| *static Vector | polar2Cartesian (const Vector &v) |
| Maps special polar coordinates to cartesian coordinates. | |
| *static VRS::Vector | cartesian2Polar (const VRS::Vector &v) |
| Inverse mapping for polar2cartesian, assuming that the up-VRSVector did not change in between. | |
| static Vector | getUp () |
| Returns simply the standard world up Vector (0,1,0). | |
| static double | getMaxAltitude () |
| Returns the maximum allowed altitude. | |
| static double | visualFlow2horizontalMovement (double screens, double fov=45.0) |
| For 'ground plate'-based navigations it can be useful to keep the horizontal movement speed proportional to the camera height. | |
| *static double | horizontalMovement2visualFlow (double units, double fov=45.0) |
| Converts horizontal lengths (in units) to visual flow (in screens). | |
| static bool | performRayRequest (int x, int y, SO< Canvas > canvas, SO< RayRequest > request) |
| performs a ray request at (x,y) in window coords. | |
Protected Member Functions | |
| GroundPlateNavigation (double yValOfGroundPlate=0.0) | |
| void | setYValOfGroundPlate (double yVal=0.0) |
| Set y value of ground plate. | |
| double | getYValOfGroundPlate () const |
| Returns the y value of ground plate. | |
| double | getHeightAboveGroundPlate (const Vector &pos) const |
| get height above ground plate | |
| bool | performRayRequest (int x, int y, SO< Canvas > canv, Vector &hitPoint) |
| performs a ray request at (x,y) in window coords | |
need to assume a virtual ground plate to work properly. The virtual ground plate's normal vector is (0,1,0) and the plate cuts the y axis at yValOfGroundPlate.
| VRS::GroundPlateNavigation::GroundPlateNavigation | ( | double | yValOfGroundPlate = 0.0 |
) | [protected] |
Maps special polar coordinates to cartesian coordinates.
The polar VRS::Vector (0,0,1) is mapped to a unit VRS::Vector on the plane through the origin with the up VRS::Vector as normal. The first two coordinates are angles in degrees, the first one specifying rotation around the up-VRSVector, the second one specifying the rotation around an orthogonal right VRS::Vector, the third coordinate specifies the length.
| * static VRS::Vector VRS::GroundPlateNavigation::cartesian2Polar | ( | const VRS::Vector & | v | ) | [static] |
Inverse mapping for polar2cartesian, assuming that the up-VRSVector did not change in between.
The resulting angles are inside the range ]-180, 180] for the first component (latitude) and inside ]-90, 90] for the second component (altitude).
| static Vector VRS::GroundPlateNavigation::getUp | ( | ) | [static] |
Returns simply the standard world up Vector (0,1,0).
| static double VRS::GroundPlateNavigation::getMaxAltitude | ( | ) | [static] |
Returns the maximum allowed altitude.
| static double VRS::GroundPlateNavigation::visualFlow2horizontalMovement | ( | double | screens, | |
| double | fov = 45.0 | |||
| ) | [static] |
For 'ground plate'-based navigations it can be useful to keep the horizontal movement speed proportional to the camera height.
This allows to specify horizontal movement speed in an intuitive way by visual flow: Looking down from an height h the time in which "one screen width of terrain" passes the camera should should be independent on the value of h. To calculate it, a field-of-view-value is needed. This method can be used by derivatives to convert from visual flow (in screens) to the absolute lengths (in units when moving in a height of 1.0). To obtain the necessary length at a heigth of h, multiply the result with h.
| * static double VRS::GroundPlateNavigation::horizontalMovement2visualFlow | ( | double | units, | |
| double | fov = 45.0 | |||
| ) | [static] |
Converts horizontal lengths (in units) to visual flow (in screens).
See visualFlow2horizontalMovement() comment for details.
| static bool VRS::GroundPlateNavigation::performRayRequest | ( | int | x, | |
| int | y, | |||
| SO< Canvas > | canvas, | |||
| SO< RayRequest > | request | |||
| ) | [static] |
performs a ray request at (x,y) in window coords.
After the call, 'request' contains the results (if any). 'request' and 'canvas' must not be NULL. Returns 'true' if the result is non-empty.
| VRS::GroundPlateNavigation::VRS_TYPEINFO | ( | GroundPlateNavigation | , | |
| InteractionTechnique | ||||
| ) |
| void VRS::GroundPlateNavigation::setYValOfGroundPlate | ( | double | yVal = 0.0 |
) | [protected] |
Set y value of ground plate.
| double VRS::GroundPlateNavigation::getYValOfGroundPlate | ( | ) | const [protected] |
Returns the y value of ground plate.
| double VRS::GroundPlateNavigation::getHeightAboveGroundPlate | ( | const Vector & | pos | ) | const [protected] |
get height above ground plate
| bool VRS::GroundPlateNavigation::performRayRequest | ( | int | x, | |
| int | y, | |||
| SO< Canvas > | canv, | |||
| Vector & | hitPoint | |||
| ) | [protected] |
performs a ray request at (x,y) in window coords