+ // --- retrieve nodes ID
+
+ SMDS_MeshCell *cell = dynamic_cast<SMDS_MeshCell*>(elem);
+ assert(cell);
+ vector<vtkIdType> nodeIds;
+ SMDS_ElemIteratorPtr it = elem->nodesIterator();
+ while(it->more())
+ {
+ int nodeId = (static_cast<const SMDS_MeshNode*>(it->next()))->getVtkId();
+ MESSAGE(" node in cell " << cell->getVtkId() << " : " << nodeId)
+ nodeIds.push_back(nodeId);
+ }
+
+ // --- insert cell in vtkUnstructuredGrid
+
+ vtkUnstructuredGrid * grid = myMesh->getGrid();
+ //int locType = elem->GetType();
+ int typ = VTK_VERTEX;//GetVtkCellType(locType);
+ int cellId = grid->InsertNextLinkedCell(typ, nodeIds.size(), &nodeIds[0]);
+ cell->setVtkId(cellId);
+ //MESSAGE("SMDS_MeshElementIDFactory::SetInVtkGrid " << cellId);
+ return cellId;