![]() |
VR-Forces 4.0.4 Class Documentation
|
A DtTerrainPatchObject contains the methods for loading a file as a terrain. More...

Public Member Functions | |
| DtTerrainPatchObject (DtDe &de, DtUniqueID id) | |
| CTOR. | |
| virtual | ~DtTerrainPatchObject () |
| DTOR. | |
| virtual bool | isGlobalScaleTerrain () const =0 |
| Is the terrain a global scale. | |
| virtual bool | getTerrainIntersection (double x, double y, double z, double vx, double vy, double vz, double &retX, double &retY, double &retZ)=0 |
| Get a terrain intersection. If no intersect found, returns false. | |
| virtual void | clearElevationCache ()=0 |
| If the patch object is using an elevation cache, clear it (otherwise do nothing). | |
| virtual void | setTerrainDefinition (const std::string &modelDefinitionName) |
| The model definition will be loaded and post processing will occur. | |
| const std::string & | terrainDefinitionName () const |
| Accessor for the terrain definition name. | |
| virtual void | enableOverlay (int type, const std::string &definition)=0 |
| Enable a specific type of overlay. | |
| virtual void | disableOverlay (int type)=0 |
| Disable a specific type of overlay. | |
| virtual void | disableAllOverlays ()=0 |
| Disable all overlays. | |
| virtual void | setOverlayScale (int type, double x, double y)=0 |
| Set the overlay scale. | |
| virtual void | setOverlayOffset (int type, double x, double y)=0 |
| Set the overlay offset. | |
| virtual void | setWrapMode (int type, int clamp)=0 |
| Set the texture wrap mode. | |
| virtual void | setBlendMode (int type, int clamp)=0 |
| Set the texture blend mode. | |
| virtual void | setRasterLayerPosition (int type, int pos)=0 |
| Set raster layer position in the operations list. | |
| virtual void | setLayerEnabled (const std::string &rule, bool status)=0 |
| Toggle layers on or off by rule regexp. | |
| virtual void | extractNodes (const std::string &rule, bool isRegEx)=0 |
| Move nodes via a rule. | |
| virtual std::string | overlayDefinition (int type)=0 |
| Non bound methods: | |
| virtual std::vector< double > | overlayScale (int type)=0 |
| Non bound methods: | |
| virtual std::vector< double > | overlayOffset (int type)=0 |
| Non bound methods: | |
| virtual DtTerrainOverlayOperation | defaultOverlay (int type)=0 |
| Non bound methods: | |
| virtual DtTerrainOverlayOperation | currentOverlay (int type)=0 |
| Non bound methods: | |
| virtual void | getTerrainExtents (DtVector &nw, DtVector &ne, DtVector &sw, DtVector &se) const =0 |
| Return the corners of the terrain, useful for calculating draping parameters. | |
| virtual DtVector | getDatabaseOrigin () const =0 |
| Return the origin of the database in database coordinates. | |
| virtual int | countNodes (const std::string &rule) const =0 |
| Count nodes via a rule. | |
| virtual bool | getExtractedNodePosition (const std::string &rule, unsigned int index, double &x, double &y, double &z) const =0 |
| Get the extracted node position. | |
| virtual bool | getExtractedNodeOrientation (const std::string &rule, unsigned int index, double &x, double &y, double &z, double &w) const =0 |
| Get the extracted node orientation (quaternion). | |
| virtual void | moveNode (DtSceneObject *object, DtModel *model, const std::string &rule, unsigned int index)=0 |
| Non bound methods: | |
| virtual DtUniqueID | uniqueID () const |
| DtUniqueID Accessor. | |
Static Public Attributes | |
| static const double | TheEarthRadius |
| The Radius of the earth, used to calculate if a terrain has global scale. | |
Protected Attributes | |
| DtDe & | myDe |
| DtUniqueID | myUniqueID |
| std::string | myTerrainDefinitionName |
A DtTerrainPatchObject contains the methods for loading a file as a terrain.
When loading a file as a terrain certain post processing steps can be taken. For example, the static trees can be extracted and replaced by dynamically generated trees.
CTOR.
| virtual makVrv::DtTerrainPatchObject::~DtTerrainPatchObject | ( | ) | [virtual] |
DTOR.
| virtual void makVrv::DtTerrainPatchObject::setTerrainDefinition | ( | const std::string & | modelDefinitionName | ) | [virtual] |
The model definition will be loaded and post processing will occur.
Reimplemented in makVrv::DtOsgTerrainPatchObject.
| const std::string& makVrv::DtTerrainPatchObject::terrainDefinitionName | ( | ) | const |
Accessor for the terrain definition name.
| virtual void makVrv::DtTerrainPatchObject::enableOverlay | ( | int | type, |
| const std::string & | definition | ||
| ) | [pure virtual] |
Enable a specific type of overlay.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::disableOverlay | ( | int | type | ) | [pure virtual] |
Disable a specific type of overlay.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::disableAllOverlays | ( | ) | [pure virtual] |
Disable all overlays.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setOverlayScale | ( | int | type, |
| double | x, | ||
| double | y | ||
| ) | [pure virtual] |
Set the overlay scale.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setOverlayOffset | ( | int | type, |
| double | x, | ||
| double | y | ||
| ) | [pure virtual] |
Set the overlay offset.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setWrapMode | ( | int | type, |
| int | clamp | ||
| ) | [pure virtual] |
Set the texture wrap mode.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setBlendMode | ( | int | type, |
| int | clamp | ||
| ) | [pure virtual] |
Set the texture blend mode.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setRasterLayerPosition | ( | int | type, |
| int | pos | ||
| ) | [pure virtual] |
Set raster layer position in the operations list.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::setLayerEnabled | ( | const std::string & | rule, |
| bool | status | ||
| ) | [pure virtual] |
Toggle layers on or off by rule regexp.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::extractNodes | ( | const std::string & | rule, |
| bool | isRegEx | ||
| ) | [pure virtual] |
Move nodes via a rule.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual std::string makVrv::DtTerrainPatchObject::overlayDefinition | ( | int | type | ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual std::vector<double> makVrv::DtTerrainPatchObject::overlayScale | ( | int | type | ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual std::vector<double> makVrv::DtTerrainPatchObject::overlayOffset | ( | int | type | ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual DtTerrainOverlayOperation makVrv::DtTerrainPatchObject::defaultOverlay | ( | int | type | ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual DtTerrainOverlayOperation makVrv::DtTerrainPatchObject::currentOverlay | ( | int | type | ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::getTerrainExtents | ( | DtVector & | nw, |
| DtVector & | ne, | ||
| DtVector & | sw, | ||
| DtVector & | se | ||
| ) | const [pure virtual] |
Return the corners of the terrain, useful for calculating draping parameters.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual DtVector makVrv::DtTerrainPatchObject::getDatabaseOrigin | ( | ) | const [pure virtual] |
Return the origin of the database in database coordinates.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual int makVrv::DtTerrainPatchObject::countNodes | ( | const std::string & | rule | ) | const [pure virtual] |
Count nodes via a rule.
This checks the current terrain contents without modifying it.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual bool makVrv::DtTerrainPatchObject::getExtractedNodePosition | ( | const std::string & | rule, |
| unsigned int | index, | ||
| double & | x, | ||
| double & | y, | ||
| double & | z | ||
| ) | const [pure virtual] |
Get the extracted node position.
| false | if the node is not found. |
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual bool makVrv::DtTerrainPatchObject::getExtractedNodeOrientation | ( | const std::string & | rule, |
| unsigned int | index, | ||
| double & | x, | ||
| double & | y, | ||
| double & | z, | ||
| double & | w | ||
| ) | const [pure virtual] |
Get the extracted node orientation (quaternion).
| false | if the node is not found. |
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::moveNode | ( | DtSceneObject * | object, |
| DtModel * | model, | ||
| const std::string & | rule, | ||
| unsigned int | index | ||
| ) | [pure virtual] |
Non bound methods:
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual DtUniqueID makVrv::DtTerrainPatchObject::uniqueID | ( | ) | const [virtual] |
DtUniqueID Accessor.
| virtual bool makVrv::DtTerrainPatchObject::isGlobalScaleTerrain | ( | ) | const [pure virtual] |
Is the terrain a global scale.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual bool makVrv::DtTerrainPatchObject::getTerrainIntersection | ( | double | x, |
| double | y, | ||
| double | z, | ||
| double | vx, | ||
| double | vy, | ||
| double | vz, | ||
| double & | retX, | ||
| double & | retY, | ||
| double & | retZ | ||
| ) | [pure virtual] |
Get a terrain intersection. If no intersect found, returns false.
Implemented in makVrv::DtOsgTerrainPatchObject.
| virtual void makVrv::DtTerrainPatchObject::clearElevationCache | ( | ) | [pure virtual] |
If the patch object is using an elevation cache, clear it (otherwise do nothing).
Use after making a large number of successive calls, such as while extracting props from a shape file
Implemented in makVrv::DtOsgTerrainPatchObject.
const double makVrv::DtTerrainPatchObject::TheEarthRadius [static] |
The Radius of the earth, used to calculate if a terrain has global scale.
DtDe& makVrv::DtTerrainPatchObject::myDe [protected] |
DtUniqueID makVrv::DtTerrainPatchObject::myUniqueID [protected] |
std::string makVrv::DtTerrainPatchObject::myTerrainDefinitionName [protected] |