From: jfa Date: Tue, 28 Feb 2012 05:22:00 +0000 (+0000) Subject: Mantis issue 0021486: EDF GEOM: Non regression test fails (MakePartition). A fix... X-Git-Tag: V6_5_0a1~57 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6175043630c53727a5109002dfd4e18403bf097a;p=modules%2Fgeom.git Mantis issue 0021486: EDF GEOM: Non regression test fails (MakePartition). A fix by Peter Kurnev. --- diff --git a/src/GEOMAlgo/GEOMAlgo_Builder_2.cxx b/src/GEOMAlgo/GEOMAlgo_Builder_2.cxx index 8b096052a..54be6ce3e 100755 --- a/src/GEOMAlgo/GEOMAlgo_Builder_2.cxx +++ b/src/GEOMAlgo/GEOMAlgo_Builder_2.cxx @@ -104,6 +104,11 @@ static const Standard_Integer , NMTTools_IndexedDataMapOfIndexedMapOfInteger& ); +//modified by NIZNHY-PKV Thu Feb 16 12:24:52 2012f +static + Standard_Boolean IsClosed(const TopoDS_Edge& aE, + const TopoDS_Face& aF); +//modified by NIZNHY-PKV Thu Feb 16 12:24:56 2012t //======================================================================= //function : FillImagesFaces @@ -314,7 +319,10 @@ void GEOMAlgo_Builder::BuildSplitFaces() } // bIsDegenerated=BRep_Tool::Degenerated(aE); - bIsClosed=BRep_Tool::IsClosed(aE, aF); + //modified by NIZNHY-PKV Thu Feb 16 12:25:04 2012f + bIsClosed=IsClosed(aE, aF); + //bIsClosed=BRep_Tool::IsClosed(aE, aF); + //modified by NIZNHY-PKV Thu Feb 16 12:25:09 2012t // const TopTools_ListOfShape& aLIE=myImages.Image(aE); aIt.Initialize(aLIE); @@ -960,6 +968,35 @@ void UpdateCandidates(const Standard_Integer theNF, } } +//modified by NIZNHY-PKV Thu Feb 16 12:25:16 2012f +//======================================================================= +//function : IsClosed +//purpose : +//======================================================================= +Standard_Boolean IsClosed(const TopoDS_Edge& aE, + const TopoDS_Face& aF) +{ + Standard_Boolean bRet; + // + bRet=BRep_Tool::IsClosed(aE, aF); + if (bRet) { + TopTools_MapOfShape aM; + TopExp_Explorer aExp(aF, TopAbs_EDGE); + for (; aExp.More(); aExp.Next()) { + const TopoDS_Shape& aEx=aExp.Current(); + // + if (aM.Add(aEx)) { + if (aEx.IsSame(aE)) { + break; + } + } + } + bRet=!bRet; + } + return bRet; +} +//modified by NIZNHY-PKV Thu Feb 16 12:25:25 2012t + /* { TopoDS_Compound aCx;