X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAlgoAPI%2FGeomAlgoAPI_MakeVolume.cpp;h=f730342fdf58d1547395c6701556cade9d6fd4ee;hb=f60dc9dd94d5d4b0ea07e3e3cbfd5b3028f0942d;hp=c942dd1cb4bb102c3e648fcf0ad134d3c73827e5;hpb=dfa8d5cc9a33eb949f364e1999dc36e75fd1ffe8;p=modules%2Fshaper.git diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_MakeVolume.cpp b/src/GeomAlgoAPI/GeomAlgoAPI_MakeVolume.cpp index c942dd1cb..f730342fd 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_MakeVolume.cpp +++ b/src/GeomAlgoAPI/GeomAlgoAPI_MakeVolume.cpp @@ -27,7 +27,7 @@ //================================================================================================= std::shared_ptr GeomAlgoAPI_MakeVolume::make(const ListOfShape& theFaces) { - GeomAlgoAPI_MakeVolume aMkVolAlgo(theFaces); + GeomAlgoAPI_MakeVolume aMkVolAlgo(theFaces, false); GeomShapePtr aResult; if(aMkVolAlgo.isDone() && !aMkVolAlgo.shape()->isNull() && aMkVolAlgo.isValid()) aResult = aMkVolAlgo.shape(); @@ -35,8 +35,10 @@ std::shared_ptr GeomAlgoAPI_MakeVolume::make(const ListOfShape& t } //================================================================================================= -GeomAlgoAPI_MakeVolume::GeomAlgoAPI_MakeVolume(const ListOfShape& theFaces) +GeomAlgoAPI_MakeVolume::GeomAlgoAPI_MakeVolume( + const ListOfShape& theFaces, const bool theAvoidInternal) { + myAvoidInternal = theAvoidInternal; build(theFaces); } @@ -65,21 +67,13 @@ void GeomAlgoAPI_MakeVolume::build(const ListOfShape& theFaces) // parameters of the volume maker aVolumeMaker->SetArguments(anArgs); aVolumeMaker->SetIntersect(true); // split edges and faces -#ifdef USE_OCCT_720 - aVolumeMaker->SetAvoidInternalShapes(true); -#endif + aVolumeMaker->SetAvoidInternalShapes(myAvoidInternal); aVolumeMaker->SetGlue(BOPAlgo_GlueOff); // building and getting result aVolumeMaker->Perform(); -#ifdef USE_OCCT_720 if (aVolumeMaker->HasErrors()) return; -#else - if(aVolumeMaker->ErrorStatus() != 0) { - return; - } -#endif TopoDS_Shape aResult = aVolumeMaker->Shape(); if(aResult.ShapeType() == TopAbs_COMPOUND) {