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

[WIP] Globe axis #278

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
Open

[WIP] Globe axis #278

wants to merge 12 commits into from

Conversation

asinghvi17
Copy link
Member

@asinghvi17 asinghvi17 commented Oct 30, 2024

This PR builds towards a 3D Globe Axis, that currently will accept a Geodesy.jl datum as the ellipsoid definition, and try to work in ECEF coordinates. We can add more functionality, integration with CoordRefSystems.jl datums, etc later.

This axis will:

  • Automatically apply a transform_func to all plots, going to 3D cartesian space.
  • Lock certain zoom keys so you can interact with this like Google Earth
  • Add a "satellite" camera-interaction API so you can move the camera in spherical space.
  • Subsample polygon meshes so that they always lie on the sphere to some approximation, not under it
  • Allow the following GlobeAxis-specific keywords:
    • zlevel: set the "z-level" i.e., some radius offset, so it's easier to layer plots (e.g earth image below, polygons above, etc
    • source: same as GeoAxis source, indicate a source CRS
  • Add a "background" sphere by default, using a modified icosphere algorithm, that could at some point be parameterized to hold some background image as well.

More todos to come. This is an expansion of the Geodesy.jl approach that was taken previously

@lupemba
Copy link

lupemba commented Nov 12, 2024

This is really awesome. Do you think it will work with Tyler.jl?

@asinghvi17
Copy link
Member Author

@lupemba I'm going to be working on that sometime this month :D - just got Tyler to support GeoMakie (though interactivity is a bit buggy).

The challenge here is that you have to figure out the intersection of the camera's view frustum (essentially a "pyramid section" along the central axis) with the sphere, and then figure out which lat/long area is visible. This is solveable, of course, but tricky, so it will be some time until I can figure out exactly how to solve that. Once that is done, then Tyler will work with this, but will have "holes" at the poles beyond -85 and +85 degrees latitude. That's an inherent limitation of the Web Mercator crs, so we'll just have to deal with it I suspect.

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

Successfully merging this pull request may close these issues.

2 participants