mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-07 18:30:55 +03:00
0025721: Wrong result obtained by Common operator.
Changes: class BOPTools_Set method: void BOPTools_Set::Add(const TopoDS_Shape& theS, const TopAbs_ShapeEnum theType) has been changed. The treatment of INTERNAL edges has been added. Added test case bugs/modalg_5/bug25721
This commit is contained in:
parent
8f7e78f4de
commit
19dcfc1bdb
@ -157,6 +157,7 @@ void BOPTools_Set::Add(const TopoDS_Shape& theS,
|
|||||||
const TopAbs_ShapeEnum theType)
|
const TopAbs_ShapeEnum theType)
|
||||||
{
|
{
|
||||||
Standard_Integer aId, aIdN;
|
Standard_Integer aId, aIdN;
|
||||||
|
TopAbs_Orientation aOr;
|
||||||
TopExp_Explorer aExp;
|
TopExp_Explorer aExp;
|
||||||
//
|
//
|
||||||
myShape=theS;
|
myShape=theS;
|
||||||
@ -173,7 +174,22 @@ void BOPTools_Set::Add(const TopoDS_Shape& theS,
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
myShapes.Append(aSx);
|
//
|
||||||
|
aOr=aSx.Orientation();
|
||||||
|
if (aOr==TopAbs_INTERNAL) {
|
||||||
|
TopoDS_Shape aSy;
|
||||||
|
//
|
||||||
|
aSy=aSx;
|
||||||
|
//
|
||||||
|
aSy.Orientation(TopAbs_FORWARD);
|
||||||
|
myShapes.Append(aSy);
|
||||||
|
//
|
||||||
|
aSy.Orientation(TopAbs_REVERSED);
|
||||||
|
myShapes.Append(aSy);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
myShapes.Append(aSx);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
myNbShapes=myShapes.Extent();
|
myNbShapes=myShapes.Extent();
|
||||||
|
33
tests/bugs/modalg_5/bug25721
Normal file
33
tests/bugs/modalg_5/bug25721
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
puts "========="
|
||||||
|
puts "OCC25721"
|
||||||
|
puts "========="
|
||||||
|
puts ""
|
||||||
|
###############################################
|
||||||
|
# Wrong result obtained by Common operator.
|
||||||
|
###############################################
|
||||||
|
|
||||||
|
restore [locate_data_file bug25721_qf1] qf
|
||||||
|
explode qf
|
||||||
|
copy qf_1 b1
|
||||||
|
copy qf_2 b2
|
||||||
|
|
||||||
|
bclearobjects
|
||||||
|
bcleartools
|
||||||
|
baddobjects b1
|
||||||
|
baddtools b2
|
||||||
|
|
||||||
|
bfillds
|
||||||
|
bbop result 0
|
||||||
|
|
||||||
|
set square 181.203
|
||||||
|
set nb_v_good 2
|
||||||
|
set nb_e_good 3
|
||||||
|
set nb_w_good 3
|
||||||
|
set nb_f_good 1
|
||||||
|
set nb_sh_good 1
|
||||||
|
set nb_sol_good 0
|
||||||
|
set nb_compsol_good 0
|
||||||
|
set nb_compound_good 1
|
||||||
|
set nb_shape_good 11
|
||||||
|
|
||||||
|
set 2dviewer 1
|
Loading…
x
Reference in New Issue
Block a user