I have downloaded a map file which I'm using as a texture on a plane. The file is a proper map file with projection in a prj-file and a tfw-file. The prj file contains:
And the tfw-file contains:
0.00000000000000 0.00000000000000 -0.03333333333333 -179.98333333333333 89.98333333333333
The original file is 10800x5400 pixels, and I've scaled it down to 2048x1024 pixels. So, how do I calculate the long/lat pair if someone clicks on point [712, 133] on my scaled down image?
Bonus things I'm wondering about:
- The image will be rescaled several times, but will keep the aspect ratio, is that a problem?
- How do I do this in reverse? IE if I want to find the x,y pair from a long/lat pair.
I've spent hours trying to read in random places about GIS, maps and whatnot but it seems to be a very steep learning curve and I'd be happy to take a shortcut as in the whole it's a fairly minor part of what I'm trying to do. Pseudo code, c#, some other language doesn't really matter, but I'm surprised how hard it has proven (for me at least) to find such hands on advice.
Sorry about the cross post, asked here originally but based on the comment I figured it might make more sense to ask here