0000684: Check Shape after boolean before refine
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include "PreCompiled.h"
|
||||
#ifndef _PreComp_
|
||||
# include <BRepAlgoAPI_Common.hxx>
|
||||
# include <BRepCheck_Analyzer.hxx>
|
||||
# include <Standard_Failure.hxx>
|
||||
#endif
|
||||
|
||||
@@ -112,6 +113,12 @@ App::DocumentObjectExecReturn *MultiCommon::execute(void)
|
||||
|
||||
Base::Reference<ParameterGrp> hGrp = App::GetApplication().GetUserParameter()
|
||||
.GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/Part/Boolean");
|
||||
if (hGrp->GetBool("CheckModel", false)) {
|
||||
BRepCheck_Analyzer aChecker(resShape);
|
||||
if (! aChecker.IsValid() ) {
|
||||
return new App::DocumentObjectExecReturn("Resulting shape is invalid");
|
||||
}
|
||||
}
|
||||
if (hGrp->GetBool("RefineModel", false)) {
|
||||
TopoDS_Shape oldShape = resShape;
|
||||
BRepBuilderAPI_RefineModel mkRefine(oldShape);
|
||||
|
||||
Reference in New Issue
Block a user