[gdal-dev] Pre-RFC for OGRSpatialReference use in GDAL and changes in how to deal with axis order issues

Even Rouault even.rouault at spatialys.com
Wed Dec 19 05:07:28 PST 2018


On mercredi 19 décembre 2018 05:46:26 CET jratike80 wrote:
> Even Rouault-2 wrote
> 
> > ICreateLayer() when receiving a OGRSpatialReference* may decide to change
> > the
> > axis mapping strategy. That is: if it receives a OGRSpatialReference with
> > AUTHORITY_COMPLIANT order, it may decide to switch to
> > TRADITIONAL_GIS_ORDER
> > and GetSpatialRef()::GetDataAxisToSRSAxisMapping() will reflect that.
> > Tools
> > like ogr2ogr will need to do the geometry axis swapping in that case
> 
> Does this guarantee that it is impossible or at least pretty difficult to
> create for example crazy shapefiles with flipped axis and rotated geometries
> even if user tries to force that with AUTHORITY_COMPLIANT mode switch?

Hi Jukka,

<jokingly>
"""THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED"""
</jokingly>

More seriously, the goal is indeed to try to make things work as currently for 
ogr2ogr, gdalwarp workflows by making drivers to report properly how they map 
the data axis to the CRS axis.
For now, the only backward incompatible change I can think of is the use of 
the low-level OGRCoordinateTransformation() interface (and gdaltransform), 
that will be axis compliant w.r.t the authoritative CRS definition, but that's 
a wanted feature I think.
With the caveat that this is only words for now, and the work remains to be 
done and will certainly bring a few surprises.

Even

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com


More information about the gdal-dev mailing list