X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FMEDCoupling%2FMEDCouplingPointSet.cxx;h=798dbeee0d392169292e8d679faa92e490d708ea;hb=e7835cba1eb17f50ef4e130c2cb8d0f54bc25083;hp=8807b35b3d0eb1046e5aa6f904b37aa11856d5a0;hpb=d4ae1f4845fe7404fb71fba82b2fc9a7f267b215;p=tools%2Fmedcoupling.git diff --git a/src/MEDCoupling/MEDCouplingPointSet.cxx b/src/MEDCoupling/MEDCouplingPointSet.cxx index 8807b35b3..798dbeee0 100644 --- a/src/MEDCoupling/MEDCouplingPointSet.cxx +++ b/src/MEDCoupling/MEDCouplingPointSet.cxx @@ -40,10 +40,10 @@ MEDCouplingPointSet::MEDCouplingPointSet():_coords(0) { } -MEDCouplingPointSet::MEDCouplingPointSet(const MEDCouplingPointSet& other, bool deepCopy):MEDCouplingMesh(other),_coords(0) +MEDCouplingPointSet::MEDCouplingPointSet(const MEDCouplingPointSet& other, bool deepCpy):MEDCouplingMesh(other),_coords(0) { if(other._coords) - _coords=other._coords->performCopyOrIncrRef(deepCopy); + _coords=other._coords->performCopyOrIncrRef(deepCpy); } MEDCouplingPointSet::~MEDCouplingPointSet() @@ -371,7 +371,7 @@ void MEDCouplingPointSet::getNodeIdsNearPoints(const double *pos, int nbOfPoints /*! * @param comm in param in the same format than one returned by findCommonNodes method (\ref numbering-indirect). * @param commI in param in the same format than one returned by findCommonNodes method (\ref numbering-indirect). - * @return the old to new correspondance array. + * @return the old to new correspondence array. */ DataArrayInt *MEDCouplingPointSet::buildNewNumberingFromCommonNodesFormat(const DataArrayInt *comm, const DataArrayInt *commIndex, int& newNbOfNodes) const @@ -1042,7 +1042,7 @@ DataArrayInt *MEDCouplingPointSet::ComputeNbOfInteractionsWithSrcCells(const MED { if(!srcMesh || !trgMesh) throw INTERP_KERNEL::Exception("MEDCouplingPointSet::ComputeNbOfInteractionsWithSrcCells : the input meshes must be not NULL !"); - MCAuto sbbox(srcMesh->getBoundingBoxForBBTree()),tbbox(trgMesh->getBoundingBoxForBBTree()); + MCAuto sbbox(srcMesh->getBoundingBoxForBBTree(eps)),tbbox(trgMesh->getBoundingBoxForBBTree(eps)); return tbbox->computeNbOfInteractionsWith(sbbox,eps); } @@ -1112,7 +1112,7 @@ MEDCouplingMesh *MEDCouplingPointSet::buildPartRange(int beginCellIds, int endCe * \param [out] beginOut valid only if \a arr not NULL ! * \param [out] endOut valid only if \a arr not NULL ! * \param [out] stepOut valid only if \a arr not NULL ! - * \param [out] arr correspondance old to new in node ids. + * \param [out] arr correspondence old to new in node ids. * * \sa MEDCouplingUMesh::buildPartOfMySelfSlice */ @@ -1181,6 +1181,9 @@ void MEDCouplingPointSet::project2DCellOnXY(const int *startConn, const int *end */ bool MEDCouplingPointSet::isButterfly2DCell(const std::vector& res, bool isQuad, double eps) { + INTERP_KERNEL::QuadraticPlanarPrecision prec(eps); + INTERP_KERNEL::QuadraticPlanarArcDetectionPrecision arcPrec(eps); + std::size_t nbOfNodes(res.size()/2); std::vector nodes(nbOfNodes); for(std::size_t i=0;i& res, bool INTERP_KERNEL::Node *tmp=new INTERP_KERNEL::Node(res[2*i],res[2*i+1]); nodes[i]=tmp; } - INTERP_KERNEL::QUADRATIC_PLANAR::_precision=eps; - INTERP_KERNEL::QUADRATIC_PLANAR::_arc_detection_precision=eps; INTERP_KERNEL::QuadraticPolygon *pol=0; if(isQuad) pol=INTERP_KERNEL::QuadraticPolygon::BuildArcCirclePolygon(nodes); @@ -1387,6 +1388,14 @@ bool MEDCouplingPointSet::areAllNodesFetched() const * mesh (with a specified precision) and (2) \a this mesh contains the same cells as * the \a other mesh (with use of a specified cell comparison technique). The mapping * from \a other to \a this for nodes and cells is returned via out parameters. + * + * If \a cellCor is null (or Py_None) it means that for all #i cell in \a other is equal to cell # i in \a this. + * + * If \a nodeCor is null (or Py_None) it means that for all #i node in \a other is equal to node # i in \a this. + * + * So null (or Py_None) returned in \a cellCor and/or \a nodeCor means identity array. This is for optimization reason to avoid building + * useless arrays for some \a levOfCheck (for example 0). + * * \param [in] other - the mesh to compare with. * \param [in] cellCompPol - id [0-2] of cell comparison method. See meaning of * each method in description of MEDCouplingPointSet::zipConnectivityTraducer(). @@ -1452,6 +1461,9 @@ void MEDCouplingPointSet::checkDeepEquivalWith(const MEDCouplingMesh *other, int * node coordinates array and (2) they contain the same cells (with use of a specified * cell comparison technique). The mapping from cells of the \a other to ones of \a this * is returned via an out parameter. + * + * If \a cellCor is null (or Py_None) it means that for all #i cell in \a other is equal to cell # i in \a this. + * * \param [in] other - the mesh to compare with. * \param [in] cellCompPol - id [0-2] of cell comparison method. See the meaning of * each method in description of MEDCouplingPointSet::zipConnectivityTraducer().