glue-viz / glue-ar

BSD 3-Clause "New" or "Revised" License
0 stars 1 forks source link

Improve calculation for scatter sphere sizes #12

Closed Carifio24 closed 9 months ago

Carifio24 commented 9 months ago

This PR partially solves #10 by calculating the sphere radius based on the viewer bounds (along with the layer state), rather than using some magic number.

This works fine in the current setup, where we're always preserving the aspect ratio of the viewer space. But if we ever decide not to do this, we'll need to do a bit more - we'll either need to generate the sphere points ourselves, or grab the ones from pyvista and give them the appropriate affine transformation.