1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-19 13:40:49 +03:00

0025788: Parallelization of the BOP Builder algorithm on second level

Changes:
class BOPAlgo_Builder
method:
  void BOPAlgo_Builder::FillIn3DParts
  (BOPCol_DataMapOfShapeListOfShape&,
   BOPCol_DataMapOfShapeShape&,
   const BOPCol_BaseAllocator& )
has been optimized and
modified to provide parallel treatment.

Correction of compilation errors

Test cases for issue CR25788
This commit is contained in:
pkv
2015-02-12 11:57:15 +03:00
committed by bugmaster
parent b70d2b0999
commit 0090ae85ab
5 changed files with 607 additions and 185 deletions

View File

@@ -20,6 +20,7 @@
#include <NCollection_List.hxx>
#include <NCollection_DataMap.hxx>
#include <NCollection_UBTreeFiller.hxx>
#include <NCollection_IncAllocator.hxx>
//
#include <gp_Pnt2d.hxx>
#include <gp_Pln.hxx>
@@ -73,6 +74,7 @@
//
#include <BOPAlgo_ShellSplitter.hxx>
static
Standard_Boolean IsGrowthShell(const TopoDS_Shape& ,
const BOPCol_IndexedMapOfShape& );
@@ -450,11 +452,14 @@ void BOPAlgo_BuilderSolid::PerformLoops()
BOPCol_ListIteratorOfListOfShape aIt;
TopoDS_Iterator aItS;
BOPCol_MapIteratorOfMapOfOrientedShape aItM;
BOPAlgo_ShellSplitter aSSp;
Handle(NCollection_BaseAllocator) aAlr;
//
myErrorStatus=0;
myLoops.Clear();
//
aAlr=new NCollection_IncAllocator();
BOPAlgo_ShellSplitter aSSp(aAlr);
//
// 1. Shells Usual
aIt.Initialize (myShapes);
for (; aIt.More(); aIt.Next()) {
@@ -535,17 +540,18 @@ void BOPAlgo_BuilderSolid::PerformLoops()
}
//
// make a new shell
TopExp_Explorer aExp;
TopoDS_Shell aShell;
aBB.MakeShell(aShell);
aBB.Add(aShell, aFF);
//
TopoDS_Iterator aItAddedF (aShell);
for (; aItAddedF.More(); aItAddedF.Next()) {
const TopoDS_Face& aF = (*(TopoDS_Face*)(&aItAddedF.Value()));
aItS.Initialize(aShell);
for (; aItS.More(); aItS.Next()) {
const TopoDS_Face& aF = (*(TopoDS_Face*)(&aItS.Value()));
//
TopExp_Explorer aEdgeExp(aF, TopAbs_EDGE);
for (; aEdgeExp.More(); aEdgeExp.Next()) {
const TopoDS_Edge& aE = (*(TopoDS_Edge*)(&aEdgeExp.Current()));
aExp.Init(aF, TopAbs_EDGE);
for (; aExp.More(); aExp.Next()) {
const TopoDS_Edge& aE = (*(TopoDS_Edge*)(&aExp.Current()));
const BOPCol_ListOfShape& aLF=aEFMap.FindFromKey(aE);
aIt.Initialize(aLF);
for (; aIt.More(); aIt.Next()) {