Just a followup post to my original inquiry...
After appending the ".gdal" to my ".dt1" files to get the
"readHeightFieldFile()" to read the DTED file format, I also had to do the
following to get the DTED to render correctly...
osg::HeightField *grid = osgDB::readHeightFieldFile("n41.dt1.gdal");
grid->setOrigin(osg::Vec3(0.0, 0.0, 0.0));
xsize = (radius * osg::PI * grid->getXInterval()) / 180.0;
ysize = (radius * osg::PI * grid->getYInterval()) / 180.0;
grid->setXInterval(xsize);
grid->setYInterval(ysize);
where "radius" is the mean radius of the Earth in meters.
Hopefully this help someone who wants to do simple display of raw DTED data
(i.e. *.dt1 files) using the default osg viewer...
-Shayne
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=53690#53690
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org