Hi,


For some reason specs generally don't introduce their main philosophy like an 
experienced user would do to a new user, but one has to deduct this slowly from 
the formal syntax descriptions. So I hoped for some more easily to digest 
document. I'm quite familiar with EPSG, so (that part of) the model seems not 
to be my problem. There are some things that I don't like about the model, so I 
might respond later to Thomas Knudsen and Martin Desruisseaux on that topic. 
But I'll first try to explain what I'm doing at the moment and hopefully 
someone can help me to get my WKT string right (and maybe also provide some 
tips on how I could do things easier with WKT).



I would like to define a custom CRS in QGIS using a PROJ pipeline in a WKT 
string so I can use the exact Helmert transformation (the error of the 
approximate Helmert transformation is 2 m in this case).



My approach has been:

  1.  Create a PROJ4 string with approximate Helmert transformation:

+proj=tmerc +lat_0=0 +lon_0=-63 +k=0.9996 +x_0=29973.97 +y_0=-1947925.94 
+ellps=intl +towgs84=1,2,3,4,5,6,7 +units=m +no_defs +type=crs

  1.  Convert the PROJ4 string in QGIS to WKT

NB: This is a bit funny, to have to use a PROJ4 string to get started, is there 
a better option?

  1.  Replace the METHOD for the "PROJ-based operation method" (based on the 
example from https://github.com/OSGeo/PROJ/pull/2521)
  2.  Replace the pipeline with the exact Helmert transformation:

NB: Is there a way to use the actual height in QGIS instead of zero? The effect 
on the horizontal coordinates is 9 cm at the point of highest elevation in the 
area of use.



WKT with PROJ-based operation method for QGIS: https://pastebin.com/Fc8eS5aJ



Input: 17.627494963  -63.234771976

Output: -10756.7796  -2480.3833



This is not what I expected. With cct, I do get the expected result when I 
replace the step +proj=unitconvert for the step +proj=tmerc (because in WKT the 
projection is in the SOURCECRS):



echo -63.234771976 17.627494963 257.5641 2020.00 | cct -I +proj=pipeline

            +step +proj=tmerc +inv +lat_0=0 +lon_0=-63 +k_0=0.9996 
+x_0=29973.97 +y_0=-1947925.94 +ellps=intl

            +step +proj=cart +ellps=intl

            +step +proj=helmert +convention=coordinate_frame +exact

                +x=1138.7432 +y=-2064.4761 +z=110.7016

                +rx=-214.615206 +ry=479.360036 +rz=-164.703951 +s=-402.32073

            +step +proj=cart +inv +ellps=WGS84

            +step +proj=unitconvert +xy_in=rad +xy_out=deg



Output: 5000.0000  1000.0000  300.0000  2020.00



PROJ can also use WKT strings, but to get the same result, some changes are 
needed:

  *   Change BOUNDCRS to COORDINATEOPERATION

NB: If I use the BOUNDCRS, I get the error "Inverse operation not available", 
which seems to suggest you could use a BOUNDCRS in cct if one specifies the 
inverse operation in the WKT?

  *   Remove ABRIDGEDTRANSFORMATION but the keep METHOD part

NB: The WKT indentation of projinfo is nice for reading, but not for editing, 
because it doesn’t use a new line for each bracket. This makes it harder to 
keep the brackets right when editing the WKT.

  *   Add projection step:

+step +proj=tmerc +inv +lat_0=0 +lon_0=-63 +k_0=0.9996 +x_0=29973.97 
+y_0=-1947925.94 +ellps=intl

NB: This is confusingly different from what QGIS needs.

  *   Remove all the line breaks and indents and replace all " with \"



How can I get this result in QGIS?



Kind regards, Jochem




Disclaimer:
De inhoud van deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde(n).
Gebruik, openbaarmaking, vermenigvuldiging, verspreiding en/of verstrekking van 
deze informatie aan derden is niet toegestaan.
Op al onze producten en diensten zijn onze algemene leveringsvoorwaarden van 
toepassing
[https://www.kadaster.nl/algemene-leveringsvoorwaarden].

Disclaimer:
This email and any files transmitted with it are confidential and intended 
solely for the use of the individual or entity to whom they are addressed.
If you are not the intended recipient, you are notified that disclosing, 
copying, distributing or taking any action in reliance on the contents of this 
information is strictly prohibited.
Our general terms and conditions of delivery apply to all our products and 
services
[https://www.kadaster.com/general-terms-and-conditions].
_______________________________________________
PROJ mailing list
PROJ@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/proj

Reply via email to