0

I have a PNG file and I need its .pgw file to be set with NAD 83 as the projection. I have created a .pgw file:

799
0
0
-799
-122.562
37.1946

However when I open the PNG in QGIS or ArcMap 10.2 it is not being placed in the right location. I have looked around on how to form a .pgw file and I think I am doing it right, but something is obviously missing. My PNG file has an associated KML which is where I got the coordinates for my .pgw file. My PNG and.pwg files have the same file name as well.

  • 2
    There's obviously no coordinate system metadata so I would check that the right one is assigned or in-use when you load it. It is probably being displayed with an assumed projection that is wrong. (Best to use a spatial format like GeoTIFF that can store all this stuff but hardly anyone does unfortunately) – mdsumner Mar 6 '14 at 20:52
1

gdal_translate should be a solution, particularly the -a_ullr and -a_srs options.

Example: gdal_translate -a_ullr -122.562 37.1946 -118.1464 33.59505 -a_srs EPSG:4269 example_input.png example_output.tif

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.