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

+towgs84=0,0,0 ignored in pipelines #881

Closed
rouault opened this Issue Mar 21, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@rouault
Member

rouault commented Mar 21, 2018

With proj master

echo "440720 3751320 0" |  src/cct +proj=pipeline +step +proj=utm +zone=11 +ellps=clrk66 +towgs84=0,0,0 +inv +step +proj=utm +zone=11 +datum=WGS84
   440721.3314   3751514.1319        0.0000           inf

whereas the equivalent cs2cs gives 440719.958709357 3751294.2109841 -4.44340920541435

If you slightly modify the towgs84 values to be almost 0 like

echo "440720 3751320 0" |  src/cct +proj=pipeline +step +proj=utm +zone=11 +ellps=clrk66 +towgs84=0.000000000001,0,0 +inv +step +proj=utm +zone=11 +datum=WGS84
   440721.3314   3751514.1319        0.0000           inf

you get the expected result. This strong discontinuity in outputs regarding very slight input parameter changes is not expected from my point of view.

The reason is that the completely 0 towgs84 is ignored in cs2cs_emulation_setup(), and so no cartesian/geodetic transformations are done to change the ellipsoids.

Suggested fix to come in a pull request

@rouault rouault added this to the 5.0.1 milestone Mar 21, 2018

rouault added a commit to rouault/proj.4 that referenced this issue Mar 21, 2018

rouault added a commit to rouault/proj.4 that referenced this issue Mar 21, 2018

@kbevers kbevers closed this in cf6b060 Mar 21, 2018

kbevers added a commit that referenced this issue Mar 21, 2018

Merge pull request #882 from rouault/fix_881
Take into account +towgs84=0,0,0 in pipeline to still imply geodetic->cartesian->geodetic (fixes #881)

kbevers added a commit that referenced this issue Mar 21, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment