[gdal-dev] gdalwarp cutline shift between raster and vector in GDAL 2.3.2

Pedro VenĂ¢ncio pedrongvenancio at gmail.com
Mon Dec 17 07:22:07 PST 2018


Hi Even,


What version of PROJ does your GDAL 2.3.2 build use ? PROJ 5 ?
> And your GDAL 2.2.2 build: PROJ 4 ?
>

GDAL 2.3.2 uses PROJ 5.2.0.
GDAL 2.2.3 uses PROJ.4 version 493
GDAL 2.2.2 uses PROJ.4 version 480



> If so, that might explain things. The ESRI:102164 translated as a proj
> string
> has no +towgs84, whereas EPSG:20790 has.
>
> With PROJ 4 and how GDAL uses it, due to the absence of a +towgs84 in one
> of
> the source/target CRS, no datum shift is performed, which is what is
> expected.
>
> With PROJ 5 and how GDAL 2.3.2 uses it, a unwanted datum shift is done (it
> is
> a bit like if the ESRI 102164 had an implicit +towgs84=0,0,0).
> I've traced this as https://github.com/OSGeo/gdal/issues/1156
>

I think this is exactly the problem!

C:\>gdalinfo --version
GDAL 2.3.2, released 2018/09/21

C:\>echo "0 0 0" | gdaltransform -s_srs "+proj=longlat +ellps=GRS80
+towgs84=100,100,100" -t_srs "+proj=longlat +ellps=GRS80"
0.000898301199977168 0.000904355202316605 100.001573113725


C:\>gdalinfo --version
GDAL 2.2.3, released 2017/11/20

C:\>echo "0 0 0" | gdaltransform -s_srs "+proj=longlat +ellps=GRS80
+towgs84=100,100,100" -t_srs "+proj=longlat +ellps=GRS80"
0 0 0


pedro at pedro-VirtualBox:~$ gdalinfo --version
GDAL 2.2.2, released 2017/09/15

pedro at pedro-VirtualBox:~$ echo "0 0 0" | gdaltransform -s_srs
"+proj=longlat +ellps=GRS80 +towgs84=100,100,100" -t_srs "+proj=longlat
+ellps=GRS80"
0 0 0


Do you think this can be fixed soon?

Thank you very much Even!

Best regards,
Pedro
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20181217/ad08a855/attachment.html>


More information about the gdal-dev mailing list