This project has moved and is read-only. For the latest updates, please go here.

Getting Lat/Lon from GeoTIFF

Topics: Algorithms, SharpMap v0.9 / v1.x
Feb 14, 2008 at 9:14 AM

I'm new to this and I'm sure I'm missing something obvious but I simply can't find what I suspect is something very, very easy to do.

Specifically, I'm using the GdalRasterLayer class to load a GeoTIFF. The image loads fine.

All I want to do is get the lat/lon from a pixel (mouse) point and the reverse, be able to specify a lat/lon and get the pixel location. The ImageToWorld and WorldToImage functions return meters. How do I convert these to lat/lons? The GeoTiff is LambertConformalConic. From the source, I see functions MetersToDegrees and DegreesToMeters in the Lambert class but I can't seem to figure out how to access them.


Thanks, Steve