[gdal-dev] OGR VRT - affine transform ?

Jukka Rahkonen jukka.rahkonen at mmmtike.fi
Fri May 24 10:37:13 PDT 2013


Jukka Rahkonen <jukka.rahkonen <at> mmmtike.fi> writes:


> 
> I wonder if it could be done by using the Spatialite SQL dialect and
> ScaleCoordinates or ReflectCoordinates
> http://www.gaia-gis.it/gaia-sins/spatialite-sql-4.0.0.html#p15
> 
> This SQL is changing the sign of y-coordinates
> select ScaleCoords(geometry,1,-1) from polygons limit 1

Frank Warmerdam in another thread just wrote that SQL dialect can be
selected in VRT and thus this might work for changing the sign of y
coordinate of the GML source data

<OGRVRTDataSource>
<OGRVRTLayer name="negative_y">
<SrcDataSource>antarctis.gml</SrcDataSource>
<LayerSRS>WGS84</LayerSRS>
<SrcSQL dialect="sqlite">SELECT ScaleCoords(geometry,1,-1) from
antarctis</SrcSQL>
</OGRVRTLayer>
</OGRVRTDataSource>

-Jukka Rahkonen-



More information about the gdal-dev mailing list