[GIS] Overlaying a .png image that comes with a world file in UTM with OpenStreetMap data

coordinate systemopenstreetmapoverlayqgisworld-file

I have received a geocoded .png image (2380 x 2396 pixels) that comes with a world file containing georeferencing information in UTM format:

worldFileParams = [0.5,0.0,0.0,-0.5,690920.0,5335407.5]

Now, I would like to overlay this image with map data. I thought about using OSM data for that purpose. In order to solve the task, I tried the following workflow:

  1. Download shapefile of OpenStreetMap data from https://mapzen.com/data/metro-extracts/
  2. Load both shapefile(s) and .png raster image in QGIS.

However, this surely naive approach hasn't worked, as both datasets are not co-located in QGIS, which is probably caused by the fact that QGIS data is provided in WGS84 (EPSG:4326) coordinates, while the png world file data is in UTM32N (EPSG:32632). When I try to reproject the png file, I receive the error

ERROR 1: latitude or longitude exceeded limits
ERROR 1: Too many points (2401 out of 2401) failed to transform,
unable to compute output bounds.

Thus, long story short: What can I do to reach my goal? Although using GDAL, QGIS, MATLAB and OpenStreetMap would come in handy for me, I am not bound to using these things.

Best Answer

What you did is correct, it is just missing a small part.

Your problem is that QGIS 'thinks' that your image is in wgs84 as there comes no projection information with it. Go into the properties for the file (in QGIS) and set the crs and voila!

Also make sure that your project is set to using a CRS (you probably also wants UTM32N there)

(I do not have QGIS available here, so I cannot give you the details)

As your question on how to style OSM shape files, please ask that as a separate one - we try to keep one topic per tread here.

Related Question