On Mon, Jun 16, 2008 at 1:52 PM, Tueller, Shayne R Civ USAF AFMC 519 SMXS/MXDEC <[EMAIL PROTECTED]> wrote:
> Thanks for the input. So is the WGS84 the default setting for osgdem? For > more clarification, this is what I'm using to build my database. > > osgdem --TERRAIN --PagedLOD -t texture/w113 -d dted/w113 -t texture/w114 -d > dted/w114 -l 4 -o myterrain/myterrain.ive There's no "default setting", it adopts the coordinate reference system of your first input, "texture/w113" in your case. > The texture/w113 and dted/w113 directories contain the geo-referenced > GeoTiff texture and corresponding DTED files to match. The same goes for > the > other directories. My resulting archive file contains a mosaic of terrain > spanning from w114 n33 to w112 n40. > > When I view the terrain and an airplane model using osgViewer, the model > appears centered at the origin and the terrain is way off in the distance. > I > want to move the model so that it is over the terrain. In order to do that, > I need to know where the terrain is relative to the origin. Your terrain is centered at (0,0,0) but you only created geometry at (-113,33,0). That is why the terrain is off in the distance. > So, given the information above, is the terrain origin at lat = 0, lon = 0? > If so, does OSG support a lat/long to x/y conversion? ASSUMING your source data is geographic (e.g. WGS84) then you have a Plate Carre projection and the conversion is simply: X=Lon, Y=Lat. If it is not geographic, then you will have to use a library like PROJ.4 to reproject it. Glenn -- Glenn Waldron : Pelican Mapping : http://pelicanmapping.com : 703-652-4791
_______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org