Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Transformation: no longer do vertical trasnformation when doing compound CRS to 2D CRS / add --3d to cs2cs #3119

Merged
merged 1 commit into from
Mar 17, 2022

Commits on Mar 16, 2022

  1. Transformation: no longer do vertical trasnformation when doing compo…

    …und CRS to 2D CRS / add --3d to cs2cs
    
    Previously, when computing transformation between a compound CRS and a
    geographic/projected 2D CRS, the behaviour was similar to implicitly
    promoting the 2D CRS to 3D CRS in the pipeline computation logic, hence
    a geoid model could be applied. But note that when doing a geographic 3D
    to geographic/projected 2D CRS transformation, we *did* not do this implicit
    promotion and if a Helmert transformation existed between the datums, it
    was done only in 2D. So this is a bit inconsistent and triggered the
    comment in OSGeo#2318 (comment)
    
    With this commit, we no longer do any vertical transformation when doing
    compound CRS to the 2D CRS, but just take the transformation of the
    horizontal part of the compound CRS to the 2D CRS.
    Said otherwise, NAD83+NAVD88 to NAD83 will no longer lead to the
    application of the geoid model. Unless you explicitly ask for the
    promotion NAD83 to 3D.
    
    Also related, in OSGeo#1563 that went to 6.3.0,
    I changed cs2cs to automatically promote to 3D the CRS as soon as one of
    them was compound, for the sake of being consistent with the past
    behaviour. But it then becomes difficult to predict PROJ behaviour
    depending on which level of it you consider...
    This commit undoes that and adds an explicit --3d switch to cs2cs, similarly to
    projinfo, to ask for promotion.
    
    Other bug fix found in the process, when using legacy syntax, +init=epsg:4979,
    (WGS 84 3D), the resulting CRS was 2D and not 3D.
    rouault committed Mar 16, 2022
    Configuration menu
    Copy the full SHA
    3e7984f View commit details
    Browse the repository at this point in the history