glue icon indicating copy to clipboard operation
glue copied to clipboard

Started adding 3D state classes to glue-core

Open astrofrog opened this issue 6 months ago • 1 comments

We should move the 3D state classes, at least the part that is unrelated to vispy. to glue-core so that they can be used by any 3D viewers including ipyvolume, without having to depend on glue-vispy-viewers. This will help us not require glue-vispy-viewers in glue-jupyter and therefore make it easier to use in jupyterlite (for which vispy doesn't work).

Still a draft at this point, will need to add tests.

astrofrog avatar Oct 02 '25 22:10 astrofrog

@astrofrog I've been playing around with using these in the ipyvolume viewers, and I'm wondering whether we also want to move certain pieces of the logic from the Vispy viewers upstream here as well. I'm thinking things like the FRB calculation that we do for the Vispy volume viewer: https://github.com/glue-viz/glue-vispy-viewers/blob/main/glue_vispy_viewers/volume/layer_artist.py#L54 or the computation of the permutation needed for the axes: https://github.com/glue-viz/glue-vispy-viewers/blob/main/glue_vispy_viewers/volume/viewer_state.py#L91.

Pretty much any 3D glue viewer is going to want this sort of functionality, so maybe it's better to put it in one place?

Carifio24 avatar Oct 28 '25 18:10 Carifio24