[vtkusers] InsertNextCell does not work on various dataset types, if directly from reader

Bryn Lloyd lloyd at itis.ethz.ch
Sat Oct 15 18:45:03 EDT 2011


Hi VTK developers


I have been fighting with a strange problem with InsertNextCell (e.g. in vtkPolyData and vtkUnstructuredGird).
In some situations this function produces incorrect results. More specifically, if I check the point ids after insertion, the ids are NOT the same as the ones I inserted.

This issue always appears if the dataset comes directly from a reader, or is copied (DeepCopy) from the output of a reader. The reason why InsertNextCell fails, is because the InsertLocation variable inside vtkCellArray is not set correctly. I can reproduce the problem with XML and legacy readers.

I have filed a bug and sent a test case, which reproduces the error:

http://vtk.org/Bug/view.php?id=12660


It would great if this bug could be fixed.

Thanks!

regards, Bryn






More information about the vtkusers mailing list