vtkGeometryFilter corrupts cell data when converting unstructured grid
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
During conversion of unstructured grid (UG) to polydata (PD) using vtkGeometryFilter cell data gets lost if the UG contains combinations of vertices/lines/polys.
The cell type switch in vtkGeometryFilter::UnstructuredGridExecute creates cells in vtkCellArrays for vertices, lines, and polys. Each of these generates its own ids, causing e.g. a subsequent UG vertex and UG line cell to map to the same PD id. Consequently, the cell data of the UG vertex is overwritten by that of the UG line.
In the attached archive is a small program that demonstrates the issue, and XML files of the input UG and the output PD, and the program output reporting the corrupted cell data array.
Note: SALOME GUI VTKViewer_GeometryFilter.cxx has probably addressed this issue by using vtkPolyData::InsertNextCell instead of building verts, lines etc. separately (http://docs.salome-platform.org/salome_6_3_1/gui/tui/GUI/index.html)