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

Support appending geometry and point sets after widget creation #166

Closed
thewtex opened this issue Jul 17, 2019 · 4 comments
Closed

Support appending geometry and point sets after widget creation #166

thewtex opened this issue Jul 17, 2019 · 4 comments
Labels
bug Something isn't working

Comments

@thewtex
Copy link
Member

thewtex commented Jul 17, 2019

@banesullivan there will be some refactoring before this is supported properly, but it is coming.

@thewtex thewtex added the bug Something isn't working label Jul 17, 2019
@banesullivan
Copy link

ref #154

@thewtex
Copy link
Member Author

thewtex commented Sep 9, 2019

@banesullivan #201 brought it a major JavaScript refactoring to address this. If any issues persists, please open an issue 🙏 - thanks!

@thewtex thewtex closed this as completed Sep 9, 2019
@banesullivan
Copy link

banesullivan commented Oct 2, 2019

@thewtex, I'm trying to leverage #201 to implement this and cannot quite figure it out. How would I append geometries to the Viewer class? This is what I have so far..

import pyvista as pv
from pyvista import examples

from itkwidgets import view, Viewer
from itkwidgets._transform_types import to_point_set, to_geometry, to_itk_image

mesh = examples.download_st_helens()
warp = mesh.warp_by_scalar()

plotter = Viewer()
plotter.geometries = [mesh,]
plotter.geometries.append(to_geometry(warp))
plotter

which doesn't add both meshes to the scene

@thewtex
Copy link
Member Author

thewtex commented Oct 22, 2019

@banesullivan does

plotter.geometries = [mesh,]
plotter.geometries = ploter.geometries + [to_geometry(warp)]

work?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants