Interactive rendering of large terrain data. More...
Classes | |
class | SoTViz |
Static class used to initialize the TerrainViz extension. More... | |
class | SoTVizDataPreprocessor |
Class used for elevation preprocessing. More... | |
class | SoTVizPreprocessor |
Abstract class used for elevation and texture preprocessing. More... | |
class | SoTVizRender |
Renders the terrain. More... | |
class | SoTVizTexturePreprocessor |
Class used for texture preprocessing. More... | |
class | SbTVizColorScale |
Class to manage colorscales More... | |
class | SbTVizData |
Abstract base class for elevation data. More... | |
class | SbTVizRegularGridData |
Regular grid data class. More... | |
class | SbTVizTexture |
Texture class. More... | |
class | SbTVizTextureList |
Handles the quadtree of textures. More... | |
class | SoTVizAltimeterSpeedometer |
Class for displaying motion information. More... | |
class | SoTVizCameraManager |
Abstract class for managing the SoTVizViewer camera. More... | |
class | SoTVizCompass |
Class for displaying an orientation compass. More... | |
class | SoTVizControls |
Class for managing the SoTVizViewer control dialog. More... | |
class | SoTVizControlsMenu |
Class displaying a toggle button in SoTVizViewer control interface. More... | |
class | SoTVizNavigationToolBase |
Base class for SoTVizViewer navigation tools. More... | |
class | SoTVizNavigationTools |
Class for SoTVizViewer navigation tools management. More... | |
class | SoTVizViewer |
Abstract base class for SoTVizViewer. More... |
Interactive rendering of large terrain data.
DEPRECATED: TerrainViz is deprecated and no longer supported since OIV 9.5.
NOTE: The classes in this extension do not exist in Open Inventor 10.0 and later.The TerrainViz extension provides a powerful tool for GIS, geoscience, and military simulation applications by allowing interactive rendering of large textured terrain.
NOTE: TerrainViz is a not separately licensed extension. You must have an OpenInventor license string.
The TerrainViz extension performs terrain visualization using an auto-adaptive mesh technique and a quadtree of textures.
It uses a multi-resolution technique that re-meshes the terrain at every frame with a constant number of triangles. The local mesh accuracy depends on the point of view and the altitude gradient. The texture level depends on the point of view only.
The module renders the terrain at an approximately constant frame rate.
Controls are provided for adjusting quality versus performance.
The TerrainViz implementation is based on the ROAM (Real-time optimally adapting meshes) algorithm:
Here are the basic steps for using TerrainViz.
SoTViz::init();
dtmRender = new SoTVizRender(); root->addChild(dtmRender);
dtmRender->loadFromXML("data/africa.xml");
data = new SbTVizRegularGridData(); data->loadDataFile("data/africa_binary.dat", SbVec3d(1./4097., 1./2500., 1./4097.), SbVec3d(0., 0., 0.)); dtmRender->setData(data); texList = new SbTVizTextureList(); texList->addTexture("data/africa_1_1.jpg", 0, SbVec2s(0, 0)); texList->addTexture("data/africa_1_4.jpg", 1, SbVec2s(0, 0)); texList->addTexture("data/africa_2_4.jpg", 1, SbVec2s(0, 1)); texList->addTexture("data/africa_3_4.jpg", 1, SbVec2s(1, 0)); texList->addTexture("data/africa_4_4.jpg", 1, SbVec2s(1, 1)); texList->addTexture("data/africa_01_16.jpg", 2, SbVec2s(0, 0)); texList->addTexture("data/africa_02_16.jpg", 2, SbVec2s(0, 1)); texList->addTexture("data/africa_03_16.jpg", 2, SbVec2s(0, 2)); texList->addTexture("data/africa_04_16.jpg", 2, SbVec2s(0, 3)); texList->addTexture("data/africa_05_16.jpg", 2, SbVec2s(1, 0)); texList->addTexture("data/africa_06_16.jpg", 2, SbVec2s(1, 1)); texList->addTexture("data/africa_07_16.jpg", 2, SbVec2s(1, 2)); texList->addTexture("data/africa_08_16.jpg", 2, SbVec2s(1, 3)); texList->addTexture("data/africa_09_16.jpg", 2, SbVec2s(2, 0)); texList->addTexture("data/africa_10_16.jpg", 2, SbVec2s(2, 1)); texList->addTexture("data/africa_11_16.jpg", 2, SbVec2s(2, 2)); texList->addTexture("data/africa_12_16.jpg", 2, SbVec2s(2, 3)); texList->addTexture("data/africa_13_16.jpg", 2, SbVec2s(3, 0)); texList->addTexture("data/africa_14_16.jpg", 2, SbVec2s(3, 1)); texList->addTexture("data/africa_15_16.jpg", 2, SbVec2s(3, 2)); texList->addTexture("data/africa_16_16.jpg", 2, SbVec2s(3, 3)); dtmRender->setTextureList(texList);
dtmRender->maxRenderedTriangles = 3500; dtmRender->triangleSizeAttenuation = 3.2; dtmRender->distanceAttenuation = 3.15;
An example program is available in $OIVHOME/examples/source/TerrainViz.