Hi QGIS community,

QGIS seems to transform coordinates differently than and what is considered the 
geodetic correct way like PROJ does. It looks like QGIS uses a zero height 
instead of the actual height of a 3D point for transforming the horizontal 
component of the coordinates. Normally, the height has as only a small 
influence on the transformation of the horizontal component of coordinates. In 
case of a large difference in the vertical of two CRSs and large height values, 
this can become significant. I'll give a practical example:

I have coordinates of a triangulation pilar in EPSG:10645 (compound projected 
CRS: DPnet Saba + Saba height) in an input file:
echo 4740.3800 1890.1200 870.3900 > input.txt

The transformation to EPSG:10638 (3D geographic CRS: BES2020 Saba) with PROJ 
9.6.0 gives correct results:
cs2cs epsg:10645 epsg:10638 --only-best -f %.9f input.txt
17.635528781    -63.237251291 827.6282[...]

I saved the output coordinates to file:
     echo 17.635528781 -63.237251291 827.6282 > output.txt

The used transformation is:
projinfo -s epsg:10645 -t epsg:10638 -o proj
Candidate operations found: 4
-------------------------------------
Operation No. 1:

unknown id, Inverse of Saba Transverse Mercator 2020 + Inverse of Saba to Saba 
height (1) + Saba to BES2020 Saba (1),
[…]

However, the location of input.txt and output.txt is visually 0.1 m different 
in QGIS (version 3.42.2):
- open input.txt in QGIS (field_1, field_2, field_3 as EPSG:10645)
- open output.txt in QGIS (field_2, field_1, field_3 as EPSG:10638), where I 
selected the first transformation (the inverse of the transformation used by 
cs2cs):
Inverse of Saba to BES2020 Saba (1) + Saba to Saba height (1) + Saba Transverse 
Mercator 2020

The wrong visualisation of the location of output.txt can be exported in QGIS 
as CSV geometry AS_XYZ:
4740.3647[...],1890.2050[...],827.6282[...]

This is exactly the xy that I get when I transform output.txt back to 
EPSG:10645 with zero height:
echo 17.635528781 -63.237251291 0 | cs2cs epsg:10638 epsg:10645 --only-best -f 
%.4f
4740.3647       1890.2052 42.4286

Is this the intended behaviour for QGIS? I don’t like it…

Jochem

_______________________________________________
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to