X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAlgoAPI%2FGeomAlgoAPI_PaveFiller.cpp;h=de0eee7eb3697b91002beda20f49729683832a45;hb=b06cf1477fb1ee46d7ae260c234cac5d0000abf2;hp=aada7a927aa49d8eb01fbf36bdf45befbe6d62cf;hpb=87b6a30a3afb8fb32e7e43ade8d9c947d9eb1684;p=modules%2Fshaper.git diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.cpp b/src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.cpp index aada7a927..de0eee7eb 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.cpp +++ b/src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.cpp @@ -40,8 +40,8 @@ GeomAlgoAPI_PaveFiller::GeomAlgoAPI_PaveFiller(const ListOfShape& theListOfShape void GeomAlgoAPI_PaveFiller::build(const ListOfShape& theListOfShape, const bool theIsMakeCompSolids) { - BOPAlgo_PaveFiller aPaveFiller; - BOPCol_ListOfShape aListOfShape; + BOPAlgo_PaveFiller* aPaveFiller = new BOPAlgo_PaveFiller; + TopTools_ListOfShape aListOfShape; for(ListOfShape::const_iterator anIt = theListOfShape.cbegin(); anIt != theListOfShape.cend(); anIt++) { const TopoDS_Shape& aShape = (*anIt)->impl(); @@ -53,22 +53,18 @@ void GeomAlgoAPI_PaveFiller::build(const ListOfShape& theListOfShape, aListOfShape.Append(aShape); } } - aPaveFiller.SetArguments(aListOfShape); - aPaveFiller.Perform(); - Standard_Integer iErr = aPaveFiller.ErrorStatus(); - if(iErr) { + aPaveFiller->SetArguments(aListOfShape); + aPaveFiller->Perform(); + if (aPaveFiller->HasErrors()) return; - } BOPAlgo_Builder* aBuilder = new BOPAlgo_Builder(); this->setImpl(aBuilder); this->setBuilderType(OCCT_BOPAlgo_Builder); aBuilder->SetArguments(aListOfShape); - aBuilder->PerformWithFiller(aPaveFiller); - iErr = aBuilder->ErrorStatus(); - if(iErr) { + aBuilder->PerformWithFiller(*aPaveFiller); + if (aBuilder->HasErrors()) return; - } TopoDS_Shape aResult = aBuilder->Shape(); if(aResult.ShapeType() == TopAbs_COMPOUND) {