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

Create proj_degree_input/output for C-API #2027

Closed
snowman2 opened this issue Mar 7, 2020 · 1 comment · Fixed by #2144
Closed

Create proj_degree_input/output for C-API #2027

snowman2 opened this issue Mar 7, 2020 · 1 comment · Fixed by #2144

Comments

@snowman2
Copy link
Contributor

snowman2 commented Mar 7, 2020

Currently there are:

proj_angular_input
proj_angular_output

Which is useful to know when the input needs to be converted from degrees to radians before performing a transform. However, some users of pyproj prefer to work in radians instead of degrees. So, to support them for the cs2cs like behavior, I check the input/output CRS to see if they are geographic. Combining that with proj_angular_input/output I am able to determine if the radians need to be converted to degrees or not. However, when attempting to support the cct like behavior with pipelines, the solution is not as obvious. So, my thought is that adding functions that check if the input needs to be in degrees would resolve this need.

Thoughts?

kbevers added a commit to kbevers/PROJ that referenced this issue Apr 11, 2020
Equivalent to proj_angular_input() and proj_angular_output() but
checking for degree units instead. proj_create_crs_to_crs() rarely, if
ever, returns pipelines that has radians as input or output so using
proj_angular_*() is not a useful check for io units of pipelines.

These two new functions should make life a bit easier for users that
generally store there angular coordinates in radians.

Closes OSGeo#2027
kbevers added a commit to kbevers/PROJ that referenced this issue Apr 11, 2020
Equivalent to proj_angular_input() and proj_angular_output() but
checking for degree units instead. proj_create_crs_to_crs() rarely, if
ever, returns pipelines that has radians as input or output so using
proj_angular_*() is not a useful check for io units of pipelines.

These two new functions should make life a bit easier for users that
generally store there angular coordinates in radians.

Closes OSGeo#2027
kbevers added a commit to kbevers/PROJ that referenced this issue Apr 11, 2020
Equivalent to proj_angular_input() and proj_angular_output() but
checking for degree units instead. proj_create_crs_to_crs() rarely, if
ever, returns pipelines that has radians as input or output so using
proj_angular_*() is not a useful check for io units of pipelines.

These two new functions should make life a bit easier for users that
generally store there angular coordinates in radians.

Closes OSGeo#2027
kbevers added a commit to kbevers/PROJ that referenced this issue Apr 12, 2020
Equivalent to proj_angular_input() and proj_angular_output() but
checking for degree units instead. proj_create_crs_to_crs() rarely, if
ever, returns pipelines that has radians as input or output so using
proj_angular_*() is not a useful check for io units of pipelines.

These two new functions should make life a bit easier for users that
generally store there angular coordinates in radians.

Closes OSGeo#2027
kbevers added a commit to kbevers/PROJ that referenced this issue Apr 12, 2020
Equivalent to proj_angular_input() and proj_angular_output() but
checking for degree units instead. proj_create_crs_to_crs() rarely, if
ever, returns pipelines that has radians as input or output so using
proj_angular_*() is not a useful check for io units of pipelines.

These two new functions should make life a bit easier for users that
generally store there angular coordinates in radians.

Closes OSGeo#2027
@snowman2
Copy link
Contributor Author

Thanks @kbevers!

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

Successfully merging a pull request may close this issue.

1 participant