I've seen a number of examples converting Latitude and Longitude into an OpenGL coordinate system. For example, this one is particularly useful. However, I haven't found relevant examples that include elevation/altitude. I was hoping someone might provide me with an example.

The original lat, long, and altitude will be in the WGS 84 ellipsoid, and OpenGL will be using the right-hand Y-Up coordinate system. Basically, I'm looking at using OpenGL to render models from Google's 3D warehouse that are associated with Google Earth. These come as collada files with a Z-Up orientation.

Thanks for any help.

Regards,

David

The original lat, long, and altitude will be in the WGS 84 ellipsoid, and OpenGL will be using the right-hand Y-Up coordinate system. Basically, I'm looking at using OpenGL to render models from Google's 3D warehouse that are associated with Google Earth. These come as collada files with a Z-Up orientation.

Thanks for any help.

Regards,

David

Do more with

EXPERT OFFICE^{®} is a registered trademark of EXPERTS EXCHANGE^{®}

http://edndoc.esri.com/arcobjects/9.2/net/9a7aa7d4-2653-4d31-b03a-1c3eff79921c.htm

If you normalise the vector returned from your longtitude and latitude calculations, scale it to the altitude you want and add that to the original vector, that should give you the answer you want. Or I am missing something?

I guess the conversion you mention will be using long and lat as angles and calculating the vector with sine and cosine. The math should be straighforward.

## Premium Content

You need an Expert Office subscription to comment.Start Free Trial