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

'End the world' outline of a crs #4240

Open
mtennekes opened this issue Aug 30, 2024 · 2 comments
Open

'End the world' outline of a crs #4240

mtennekes opened this issue Aug 30, 2024 · 2 comments

Comments

@mtennekes
Copy link

For visualisation purposes we would like to calculate the 'boundaries' of the earth from a given crs.

A naive approach that I took earlier was to transform the longlat -180, - 180, -90, - 90 bounding box to the target crs:

image

However, this clearly does not work in general. Is there a way to obtain the outline of a crs?

See also r-tmap/tmap#929

@rouault
Copy link
Member

rouault commented Aug 30, 2024

I would suggest you use proj_trans_bounds() : https://proj.org/en/9.4/development/reference/functions.html#c.proj_trans_bounds

@mtennekes
Copy link
Author

Thx @rouault but to clarify: I'm looking for the visible boundary, expecting a polygon rather than a box. In the map above, the contour that separates blue/green from white.

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

No branches or pull requests

2 participants