-
-
Notifications
You must be signed in to change notification settings - Fork 312
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
3D Camera Orientation Widget #2944
base: master
Are you sure you want to change the base?
Conversation
Compile Times benchmarkNote, that these numbers may fluctuate on the CI servers, so take them with a grain of salt. All benchmark results are based on the mean time and negative percent mean faster than the base branch. Note, that GLMakie + WGLMakie run on an emulated GPU, so the runtime benchmark is much slower. Results are from running: using_time = @ctime using Backend
# Compile time
create_time = @ctime fig = scatter(1:4; color=1:4, colormap=:turbo, markersize=20, visible=true)
display_time = @ctime Makie.colorbuffer(display(fig))
# Runtime
create_time = @benchmark fig = scatter(1:4; color=1:4, colormap=:turbo, markersize=20, visible=true)
display_time = @benchmark Makie.colorbuffer(display(fig))
|
There are some nice textures we could use for a KSP like navball here - all under a FOSS license |
Oh, cool. I think as a default we'd want a texture with x/y/z marked rather than north, south, etc, but I could try to be compatible with those textures. |
I could do a spherical axis instead, that might actually be better since it's more customizable. Will send the code when I can. |
I was planning to generate a texture with Makie code. That could be customized, though you probably want to do it in CairoMakie because fxaa makes this kinda of ugly in GLMakie. |
TODO:
|
Description
Old Description
Implements the Widget from #2624, which allows you to orient a 3D axis by clicking on different faces of the mesh, or rotating that mesh with mouse interactions. This will need some adjustments after #2746.I think this looks pretty bad atm so I'm open to suggestions.
Blender has this with only 6 directions, which is a bit too coarse imo.
Maybe this should be similar to the Navball in Kerbal Space Program, which could also double as an (external) axis type thing. To orient the plot we could allow different angular step size, which we could round to on click. (Ignore all the UI around the ball)
This pr is in some sense a continuation/more polished implementation of #2624. The goal is to provide another tool for controlling and understanding the orientation of the 3D camera. I'm taking inspiration from Kerbal Space Program here, which uses a textured ball to represent the orientation of a rocket relative to the planets surface.
My current Makie version looks like this:
The background color choice in KSP, light blue and brown, is probably meant to represent the sky and the ground. (The blue side always faces up). I wanted to avoid dark backgrounds for this, so I switched from brown to green, which I hope still gets that thought across. The green is a bit darker than the blue, so it should still be differentiable with color blindness.
This will need some adjustments after #2746.
TODO:
Type of change
Checklist