X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FINTERP_KERNEL%2FMappedBarycentric2DIntersectorP1P1.txx;h=8dc1cc360248632713656171df78c00966f7e867;hb=b832b15337be013a56e0976170e5e235b89fcb03;hp=f399844d6eee91b0dcc058c581a6da728c3e1303;hpb=9727e779d56acece98be02cdccd0f99cc5ef0fa2;p=tools%2Fmedcoupling.git diff --git a/src/INTERP_KERNEL/MappedBarycentric2DIntersectorP1P1.txx b/src/INTERP_KERNEL/MappedBarycentric2DIntersectorP1P1.txx index f399844d6..8dc1cc360 100644 --- a/src/INTERP_KERNEL/MappedBarycentric2DIntersectorP1P1.txx +++ b/src/INTERP_KERNEL/MappedBarycentric2DIntersectorP1P1.txx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2019 CEA/DEN, EDF R&D +// Copyright (C) 2007-2024 CEA, EDF // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -43,7 +43,7 @@ namespace INTERP_KERNEL { std::vector CoordsT; PlanarIntersector::getRealTargetCoordinates(OTT::indFC(icellT),CoordsT); - int nbOfNodesT=CoordsT.size()/SPACEDIM; + ConnType nbOfNodesT=ToConnType(CoordsT.size())/SPACEDIM; for(typename std::vector::const_iterator iter=icellsS.begin();iter!=icellsS.end();iter++) { NormalizedCellType tS=PlanarIntersector::_meshS.getTypeOfElement(OTT::indFC(*iter)); @@ -53,12 +53,12 @@ namespace INTERP_KERNEL PlanarIntersector::getRealSourceCoordinates(OTT::indFC(*iter),CoordsS); std::vector CoordsTTmp(CoordsT); if(SPACEDIM==3) - PlanarIntersector::projectionThis(&CoordsS[0],&CoordsTTmp[0],CoordsS.size()/SPACEDIM,nbOfNodesT); + PlanarIntersector::projectionThis(&CoordsS[0],&CoordsTTmp[0],ToConnType(CoordsS.size())/SPACEDIM,nbOfNodesT); const ConnType *startOfCellNodeConnT=PlanarIntersector::_connectT+OTT::conn2C(PlanarIntersector::_connIndexT[icellT]); - for(int nodeIdT=0;nodeIdT::ind2C(startOfCellNodeConnT[nodeIdT])]; - if( PointLocatorAlgos::isElementContainsPointAlg2D(&CoordsTTmp[nodeIdT*SPACEDIM],&CoordsS[0],4,PlanarIntersector::_precision) ) + if( PointLocatorAlgos::isElementContainsPointAlg2DSimple(&CoordsTTmp[nodeIdT*SPACEDIM],&CoordsS[0],4,PlanarIntersector::_precision) ) { double mco[2]; // mapped coordinates in the quad4 std::vector coo(4); @@ -74,7 +74,7 @@ namespace INTERP_KERNEL resLoc[3] = mco[0] * (1.-mco[1]); const ConnType *startOfCellNodeConnS=PlanarIntersector::_connectS+OTT::conn2C(PlanarIntersector::_connIndexS[*iter]); - for(int nodeIdS=0;nodeIdS<4;nodeIdS++) + for(ConnType nodeIdS=0;nodeIdS<4;nodeIdS++) { if(fabs(resLoc[nodeIdS])>PlanarIntersector::_precision) { @@ -96,13 +96,13 @@ namespace INTERP_KERNEL } template - int MappedBarycentric2DIntersectorP1P1::getNumberOfRowsOfResMatrix() const + typename MyMeshType::MyConnType MappedBarycentric2DIntersectorP1P1::getNumberOfRowsOfResMatrix() const { return PlanarIntersector::_meshT.getNumberOfNodes(); } template - int MappedBarycentric2DIntersectorP1P1::getNumberOfColsOfResMatrix() const + typename MyMeshType::MyConnType MappedBarycentric2DIntersectorP1P1::getNumberOfColsOfResMatrix() const { return PlanarIntersector::_meshS.getNumberOfNodes(); }