[vtkusers] vtkPointSource output has N points and 1 cell?

David Doria daviddoria at gmail.com
Mon Nov 28 11:10:06 EST 2011


The output of vtkPointSource has the requested number of points and 1
cell.  I looked in vtkPointSource.cxx and it has:

  newVerts = vtkCellArray::New();
newVerts->Allocate(newVerts->EstimateSize(1,this->NumberOfPoints));
newVerts->InsertNextCell(this->NumberOfPoints);

and then goes on to do this in a loop:

  newVerts->InsertCellPoint(newPoints->InsertNextPoint(x));

My question is which type of cell is this that has no connectivity but
more than 1 point? And why does vtkPointSource not just use a
vtkVertexGlyphFilter to create an output with the name number of
vertices as points?

David



More information about the vtkusers mailing list