From: Anthony Geay Date: Wed, 28 Dec 2022 09:20:40 +0000 (+0100) Subject: WIP X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=refs%2Fheads%2Fagy%2Fedf26666;p=tools%2Fmedcoupling.git WIP --- diff --git a/src/MEDLoader/MEDFileBlowStrEltUp.cxx b/src/MEDLoader/MEDFileBlowStrEltUp.cxx index db2b47512..aba6b59f6 100644 --- a/src/MEDLoader/MEDFileBlowStrEltUp.cxx +++ b/src/MEDLoader/MEDFileBlowStrEltUp.cxx @@ -410,6 +410,9 @@ MCAuto LocInfo::BuildMeshCommon(INTERP_KERNEL::NormalizedCellT fakeF->setGaussLocalizationOnType(gt,loc.getRefCoords(),loc.getGaussCoords(),loc.getGaussWeights()); ptsForLoc=fakeF->getLocalizationOfDiscr(); // + if(ptsForLoc->getNumberOfComponents()!=3) + ptsForLoc = ptsForLoc->changeNbOfComponents(3,0.0); + // return geoMesh; } @@ -533,7 +536,11 @@ MCAuto LocInfo::BuildMeshPipeSEG3(const DataArrayDouble *angle, geoMesh2->convertQuadraticCellsToLinear(); dir=geoMesh2->buildDirectionVectorField(); } - MCAuto rot(dir->getArray()->fromCartToSpher()); + MCAuto dirArr; + dirArr.takeRef(dir->getArray()); + if(dir->getNumberOfComponents()!=3) + dirArr = dirArr->changeNbOfComponents(3,0.0); + MCAuto rot(dirArr->fromCartToSpher()); std::size_t nbCompo(ptsForLoc->getNumberOfComponents()); MCAuto secPts(section->getCoords()->changeNbOfComponents(nbCompo,0.)); {