[vtkusers] updating vtkImageData ?

Anders Wallin anders.e.e.wallin at gmail.com
Mon Feb 13 09:14:07 EST 2012


> If you add the actor after myimg.modify(), it shows the updated image.
> You are earlier modifying the data, but not adding the updated actor to the
> renderer.
> myim.modify()
> ren.AddActor(ia)

So when I want an update I would do something like:
ren.RemoveActor(ia)
ia.modify()
ren.AddActor(ia)
ren.Render()

That doesn't look very nice. I thought the idea with VTK is that you
set up a rendering pipeline once, and you can then modify the data
source or filters/algorithms in the pipeline, and then do an update
and see the rendered result update..

Anders



More information about the vtkusers mailing list