[vtk-developers] Bug/feature request for Widgets/vtkSphereWidget
Prabhu Ramachandran
prabhu_r at users.sf.net
Sat Dec 17 01:55:34 EST 2005
Hi,
I just discovered a small problem with the vtkSphereWidget. It
appears that vtkSphereWidget could be a subclass of
vtkPolyDataSourceWidget but this is not the case neither is the
vtkLineWidget or vtkPointWidget. OTOH, vtkPlaneWidget is a subclass
of vtkPolyDataSourceWidget.
Anyway, the problem is that vtkSphereWidget does not have an
UpdatePlacement method. So if you set the sphere's position like so:
w = vtkSphereWidget()
w.SetCenter(x,y,z)
pd = vtkPolyData()
w.GetPolyData(pd)
Then, unless you interact with the sphere, the GetPolyData method
produces poly data that is not up-to-date. Essentially,
this->SphereSource->Update(); needs to be called for the poly data to
be in sync.
My request is that either vtkSphereWidget be re-written to be a
subclass of vtkPolyDataSourceWidget or atleast an UpdatePlacement be
added to it.
It would be great if this were added to the 5.0 branch as well.
Thanks.
cheers,
prabhu
More information about the vtk-developers
mailing list