I'm trying for some time to convert a weather radar map (gnomonical projection) to mercator (EPSG_3395) and then layout it onto third-party web map so far unsuccessfully.

The original image: Raw picture

The projection can be defined by: +proj=gnom +lat_0=50.008 +lon_0=14.447 +x_0=0 +y_0=0

I can convert pixel coordinates from origin of the projection with ratio 1:1000 by:

cs2cs +proj=gnom +lat_0=50.008 +lon_0=14.447 +to +init=epsg:4326 -f "%.9f"

which gives me those corner coordinates:

    -301500 +217500 top     left:  10.062746833 51.879564163
    +427500 -310500 bottom  right: 20.076498030 47.082819838

My next step is to add metadata to image:

gdal_translate -a_srs "+proj=gnom +lat_0=50.008 +lon_0=14.447" -a_ullr -301500 +217500 729000 528000
            infile.png translated.png

Finally when I try to reproject whole image by:

gdalwarp -overwrite -s_srs "+proj=gnom +lat_0=50.008 +lon_0=14.447" -t_srs EPSG:3395 translated.png warped.png

I get wrong result. I'm new to GDAL. Where am I wrong and how can I rewrite my commands to make the reprojection go well?

  • Tip: use gdalinfo to see data about your raster files including their location.
    – Spacedman
    Commented Sep 9, 2019 at 22:03

1 Answer 1


gdal_translate needs the coordinates of the corners - I don't know where your " 729000 528000" come from - I guess the width/height? No, it should be the coordinates:

 gdal_translate -a_srs "+proj=gnom +lat_0=50.008 +lon_0=14.447" -a_ullr -301500 +217500 427500 -310500 QQNDR.png located.tiff

Another change I've made is to name the output .tiff since its a TIFF file.

After reprojection it loads perfectly into QGIS in the right location:

gdalwarp -overwrite -s_srs "+proj=gnom +lat_0=50.008 +lon_0=14.447" -t_srs EPSG:3395 located.tiff warped.tiff

enter image description here

  • Thank you, I really assumed the third and the fourth parameter is width and height. Now everything goes well.
    – W. Smith
    Commented Sep 10, 2019 at 8:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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