itkwidgets icon indicating copy to clipboard operation
itkwidgets copied to clipboard

geometery_colors, other properties not working when passed

Open fcollman opened this issue 3 years ago • 3 comments

On my installlations (and on binder right now), passing some initial settings for rendering do not work.

For example, passing geometry_colors=['g'] does not cause the Mesh example to initially render green.

viewer=view(geometries=mesh, geometry_colors=['g'] , ui_collapsed=True)

However, if you start the viewer and then display it and then set the colors as an np.array

viewer.geometry_colors = np.array([[0,1,0]], dtype=np.float32)

then the colors do change dynamically. But you can't set them to start (everything is always red)..

checking the viewer.get_state('geometry_colors') indicates that the front end did receive the correct data when passing geometry_colors to the view function, but it is not properly syncing what is rendered.

fcollman avatar Aug 21 '21 17:08 fcollman

I believe this is effecting a number of other options as well.

fcollman avatar Aug 21 '21 17:08 fcollman

this is probably related to #398

fcollman avatar Aug 21 '21 21:08 fcollman

Same issue here. Problem also applies to geometry_opacities. viewer.get_state returns the correct values but always shows the default settings.

cozenom avatar Nov 24 '21 02:11 cozenom