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

0028442: Incorrect result of 3D offset operation in mode Complete, Join type - Intersection

1. For the support of the new configurations of the input shapes for the 3D offset algorithm
(shapes containing the faces with holes, which are growing during offset operation and
sometimes (depending on the offset value) even kill the faces themselves) the new function
*FindFacesInsideHoleWires* has been implemented. This new function looks for the splits of
the offset face located inside the new hole wire built from offset edges of the edges of the
hole wires of the original face. All found splits are simply removed.

2. Test cases for the issue.
This commit is contained in:
emv
2017-02-09 08:57:49 +03:00
committed by bugmaster
parent b66f375869
commit 0da0275c18
98 changed files with 2931 additions and 105 deletions

View File

@@ -4022,5 +4022,30 @@ void BRepOffset_Tool::CorrectOrientation(const TopoDS_Shape& SI,
}
//=======================================================================
//function : CheckNormals
//purpose :
//=======================================================================
Standard_Boolean BRepOffset_Tool::CheckPlanesNormals(const TopoDS_Face& theFace1,
const TopoDS_Face& theFace2,
const Standard_Real theTolAng)
{
BRepAdaptor_Surface aBAS1(theFace1, Standard_False), aBAS2(theFace2, Standard_False);
if (aBAS1.GetType() != GeomAbs_Plane ||
aBAS2.GetType() != GeomAbs_Plane) {
return Standard_False;
}
//
gp_Dir aDN1 = aBAS1.Plane().Position().Direction();
if (theFace1.Orientation() == TopAbs_REVERSED) {
aDN1.Reverse();
}
//
gp_Dir aDN2 = aBAS2.Plane().Position().Direction();
if (theFace2.Orientation() == TopAbs_REVERSED) {
aDN2.Reverse();
}
//
Standard_Real anAngle = aDN1.Angle(aDN2);
return (anAngle < theTolAng);
}