From: Christophe Bourcier Date: Mon, 7 Dec 2020 06:46:27 +0000 (+0100) Subject: Fix MEDReader to be able to read big meshes with connectivity ids length > 2**31... X-Git-Tag: V9_7_0a1~15 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=refs%2Fheads%2Fcbr%2Ffix_loading_med_file_int64_connectivity;p=modules%2Fparavis.git Fix MEDReader to be able to read big meshes with connectivity ids length > 2**31 (int32 limit) --- diff --git a/src/Plugins/MEDReader/plugin/MEDLoaderForPV/MEDFileFieldRepresentationTree.cxx b/src/Plugins/MEDReader/plugin/MEDLoaderForPV/MEDFileFieldRepresentationTree.cxx index 87404a49..a8396b31 100644 --- a/src/Plugins/MEDReader/plugin/MEDLoaderForPV/MEDFileFieldRepresentationTree.cxx +++ b/src/Plugins/MEDReader/plugin/MEDLoaderForPV/MEDFileFieldRepresentationTree.cxx @@ -270,7 +270,7 @@ void AssignDataPointerToVTK(typename MEDFileVTKTraits::VtkType *vtkTab, typen // here copy is always assumed. template -void AssignDataPointerOther(VTKT *vtkTab, MCT *mcTab, int nbElems) +void AssignDataPointerOther(VTKT *vtkTab, MCT *mcTab, vtkIdType nbElems) { typedef typename VTKT::ValueType VTKType; if ( sizeof( VTKType ) == sizeof( typename MCT::Type )) @@ -732,7 +732,7 @@ vtkUnstructuredGrid *MEDFileFieldRepresentationLeaves::buildVTKInstanceNoTimeInt MCAuto typesSafe(typesMC); MCAuto cellLocationsSafe(cellLocationsMC),cellsSafe(cellsMC),faceLocationsSafe(faceLocationsMC),facesSafe(facesMC); // - int nbOfCells(typesSafe->getNbOfElems()); + vtkIdType nbOfCells(typesSafe->getNbOfElems()); vtkUnstructuredGrid *ret(vtkUnstructuredGrid::New()); vtkUnsignedCharArray *cellTypes(vtkUnsignedCharArray::New()); AssignDataPointerOther(cellTypes,typesSafe,nbOfCells);