[gdal-dev] Question in orthographic projection usage with PROJ4

Andre Joost andre+joost at nurfuerspam.de
Wed Feb 1 07:28:32 PST 2017


Am 31.01.2017 um 17:46 schrieb 
Niels.vonFestenberg-Packisch.ext at rohde-schwarz.com:
> Hi all,
> I would like to transform local cartesian coordinates into longitude and
> latitude. According to all the documentation I could find, I tried doing
> this (in C++, specifying a center for the orthographic projection at 56 N
> 15 E):
>
> projPJ cSourceProjection = pj_init_plus("+proj=ortho +ellps=WGS84
> +datum=WGS84 +lat_0=56 +lon_0=15 +no_defs");
> projPJ cTargetProjection = pj_init_plus("+proj=longlat +ellps=WGS84
> +datum=WGS84 +no_defs");


>
> Could you maybe give me a hint what is going wrong here?
>

You have not told GDAL that your projected data is in meters, so add 
+units=m to your "from" proj.4 string.

HTH,
André Joost




More information about the gdal-dev mailing list