I get the following error when trying to use GDAL 3.1.2 for computing the LLA from my custom gnomonic projections. Am I setting it up wrong? Missing some information/files? Would it be a misconfigured build? It worked fine for me in GDAL2.

Cannot find coordinate operations 
from `PROJCRS["Customized Gnomonic",BASEGEOGCRS["Customized WGS84",DATUM["Custom Datum",ELLIPSOID["WGS84 Radius + Elevation",6379509.75,inf,LENGTHUNIT["metre",1,ID["EPSG",9001]]]],PRIMEM["Greenwich",0,ANGLEUNIT["degree",0.0174532925199433,ID["EPSG",9122]]]],CONVERSION["Gnomonic",METHOD["Gnomonic"],PARAMETER["Latitude of natural origin",41.7480066139774,ANGLEUNIT["degree",0.0174532925199433],ID["EPSG",8801]],PARAMETER["Longitude of natural origin",-112.023800209591,ANGLEUNIT["degree",0.0174532925199433],ID["EPSG",8802]],PARAMETER["False easting",0,LENGTHUNIT["metre",1],ID["EPSG",8806]],PARAMETER["False northing",0,LENGTHUNIT["metre",1],ID["EPSG",8807]]],CS[Cartesian,2],AXIS["(E)",east,ORDER[1],LENGTHUNIT["metre",1,ID["EPSG",9001]]],AXIS["(N)",north,ORDER[2],LENGTHUNIT["metre",1,ID["EPSG",9001]]]]' 
to `EPSG:4326'

Basic code to set it up:

var sr = new SpatialReference(null);
sr.SetProjCS("Customized Gnomonic");
sr.SetGeogCS("Customized WGS84", "Custom Datum", "WGS84 Radius + Elevation",
            _earthRadius + origin.Altitude, double.PositiveInfinity, null, 0.0, null, 1.0);
sr.SetGnomonic(origin.Latitude, origin.Longitude, 0.0, 0.0);
  • 1
    There is a problem in the base geographic crs definition, wich has an infinite inverse flattening. Spheres have infinite inverse flattening but in the crs definition a zero for that parameter is interpreted as infinite. If you are trying to define a spheric datum, it must be DATUM["Custom Datum",ELLIPSOID["WGS84 Radius + Elevation",6379509.75,0,LENGTHUNIT["metre",1,ID["EPSG",9001]]]]. I don't know how to do it with the SetGeogCS() method. Aug 1, 2020 at 17:24
  • Yes, I'm trying to define something that is the same as WGS84 except for the radius of the earth.
    – Brannon
    Aug 2, 2020 at 2:51
  • Putting a zero in there in place of infinity does seem to get me farther. Thanks. That was an intentional GDAL2 -> GDAL3 change?
    – Brannon
    Aug 2, 2020 at 2:54
  • 1
    No, it is in the OGC standard definition for WKT representations of CRSes, section 8.2.1 (docs.opengeospatial.org/is/18-010r7/18-010r7.html#66) requirement a). Please, create the answer to your question, you can also accept it. Aug 2, 2020 at 5:49

1 Answer 1


As mentioned in the comments, my issue was in using double.PositiveInfinity for the inverse flattening. The instructions specifically state to use zero when infinity is wanted. Apparently GDAL v2 supports either, but GDAL v3 only supports the zero input. See https://docs.opengeospatial.org/is/18-010r7/18-010r7.html#66

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.