[vtkusers] vtkPolyData::Reset()

Rioux, Francois (AEREX) Francois.Rioux.AEREX at drdc-rddc.gc.ca
Wed May 29 10:14:41 EDT 2002


Hi, 

	In my application, I use a vtkPolyData and I fill it with points to
view these points in 3D. I periodically refresh my image, so I need to flush
the old points
to fill the list with the new points. So, I thought that vtkPolyData::Reset
cleaned up all the cells and links, but that is not the case...The Cell
attribute allocates more and more memory and does not release it. What
method should I use to Reset the polyData???

I use that code to fill my polyData:

count = m_points->InsertNextPoint(j, 320-i-1, disparityImage[i*width+j]);
m_pointsPolyData->InsertNextCell(VTK_VERTEX, 1, &count);

and later, 
	m_pointsPolyData->SetPoints(m_points);

Thanks in advance, Francois




More information about the vtkusers mailing list