[vtkusers] Deleting a widget

Leonardo M. Ramé l.rame at griensu.com
Mon Sep 20 16:46:36 EDT 2010


On 2010-09-20 16:44:12 -0400, John Drescher wrote:
> >
> > Here is what I did last week..
> >
> > class MyClass
> > {
> > ...
> > public:
> > typedef QList<VTKObjPtr>        VTKObjPtrList;
> > protected:
> > VTKObjPtrList                   m_lstVTKObjects;
> >
> > ..
> > }
> >
> > Then just create the object like this:
> >
> > MyClass:SomeMember()
> > {
> >  vtkSmartPointer<vtkImageEllipsoidSource> pImageSource =
> > vtkSmartPointer<vtkImageEllipsoidSource>::New();
> >  m_lstVTKObjects.append(pImageSource);
> > }
> >
> 
> Oops. Missed the typedef for VTKObjPtr
> 
> Here goes:
> 
> typedef vtkSmartPointer<vtkObject>		VTKObjPtr;
> 
> -- 
> John M. Drescher

Nice, I'll copy your method :)

-- 
Leonardo M. Ramé
http://leonardorame.blogspot.com



More information about the vtkusers mailing list