1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0028189: Result of Boolean operation is non-manifold wire

1. The result of Boolean operation on the arguments of collection type, containers WIRE/SHELL/COMPSOLID, is also a collection.
The containers of type WIRE included into result should now also (as the SHELLs) have coherent orientation of its sub-shapes.
For that the new method has been implemented (BOPTools_AlgoTools::OrientEdgesOnWire(TopoDS_Shape&)) which reorients edges for correct ordering.
The duplicating containers, i.e. containers with the contents completely included in other containers, are now avoided in the result of BOP.
2. The result of Fuse operation on Compsolids is now also will be Compsolid.
3. Documentation has been updated.
4. New test cases for the issue.
5. Adjusting test cases to current behavior.

Correction of test case bugs/modalg_4/bug726_2 according to the new behavior
This commit is contained in:
emv
2016-12-29 15:42:08 +03:00
committed by apn
parent 400af1bcf6
commit 77a11d3df1
43 changed files with 626 additions and 47 deletions

View File

@@ -15,6 +15,7 @@
#include <BOPTest.hxx>
#include <BOPTools_AlgoTools.hxx>
#include <BOPTools_AlgoTools2D.hxx>
#include <DBRep.hxx>
#include <IntTools_Context.hxx>
@@ -23,8 +24,8 @@
#include <TopoDS_Face.hxx>
#include <TopoDS_Shape.hxx>
static Standard_Integer attachpcurve (Draw_Interpretor&, Standard_Integer, const char**);
static Standard_Integer attachpcurve (Draw_Interpretor&, Standard_Integer, const char**);
static Standard_Integer edgestowire (Draw_Interpretor&, Standard_Integer, const char**);
//=======================================================================
@@ -41,6 +42,7 @@ static Standard_Integer attachpcurve (Draw_Interpretor&, Standard_Integer, con
// Commands
theCommands.Add("attachpcurve", "attachpcurve eold enew face", __FILE__, attachpcurve, group);
theCommands.Add("edgestowire" , "edgestowire wire edges" , __FILE__, edgestowire , group);
}
//=======================================================================
@@ -102,3 +104,27 @@ static Standard_Integer attachpcurve(Draw_Interpretor& theDI,
return 0;
}
//=======================================================================
//function : edgestowire
//purpose : Orients the edges to make wire
//=======================================================================
static Standard_Integer edgestowire(Draw_Interpretor& theDI,
Standard_Integer theNArg,
const char ** theArgVal)
{
if (theNArg != 3) {
theDI << "Use: edgestowire wire edges\n";
return 1;
}
//
TopoDS_Shape anEdges = DBRep::Get(theArgVal[2]);
if (anEdges.IsNull()) {
theDI << "no edges\n";
return 1;
}
//
BOPTools_AlgoTools::OrientEdgesOnWire(anEdges);
DBRep::Set(theArgVal[1], anEdges);
return 0;
}