mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
0029463: Regression relation to 691 version: Method BndBox::IsOut() returns true for point lying on the planar face
Correct the method BRepBndLib::Add so that to enlarge the bounding box on the tolerance of edges which curves participate in calculation of the box.
This commit is contained in:
parent
d2c909178e
commit
b1ee6d0e4b
@ -115,8 +115,9 @@ void BRepBndLib::Add(const TopoDS_Shape& S, Bnd_Box& B, Standard_Boolean useTria
|
||||
}
|
||||
else {
|
||||
for (;ex2.More();ex2.Next()) {
|
||||
BC.Initialize(TopoDS::Edge(ex2.Current()));
|
||||
BndLib_Add3dCurve::Add(BC, BRep_Tool::Tolerance(F), B);
|
||||
const TopoDS_Edge& anEdge = TopoDS::Edge(ex2.Current());
|
||||
BC.Initialize(anEdge);
|
||||
BndLib_Add3dCurve::Add(BC, BRep_Tool::Tolerance(anEdge), B);
|
||||
}
|
||||
B.Enlarge(BRep_Tool::Tolerance(F));
|
||||
}
|
||||
|
14
tests/lowalgos/begin
Normal file
14
tests/lowalgos/begin
Normal file
@ -0,0 +1,14 @@
|
||||
if { [array get Draw_Groups "TOPOLOGY Check commands"] == "" } {
|
||||
pload TOPTEST
|
||||
pload AISV
|
||||
}
|
||||
# To prevent loops limit to 1 minutes
|
||||
cpulimit 60
|
||||
|
||||
if { [info exists imagedir] == 0 } {
|
||||
set imagedir .
|
||||
}
|
||||
|
||||
if { [info exists test_image ] == 0 } {
|
||||
set test_image photo
|
||||
}
|
21
tests/lowalgos/bnd/bug29463
Normal file
21
tests/lowalgos/bnd/bug29463
Normal file
@ -0,0 +1,21 @@
|
||||
puts "========"
|
||||
puts "OCC29463"
|
||||
puts "========"
|
||||
puts ""
|
||||
#################################################
|
||||
# Method BndBox::IsOut() returns true for point lying on the planar face
|
||||
#################################################
|
||||
|
||||
restore [locate_data_file bug29463_face13_691.brep] f
|
||||
|
||||
set x 165.16888924444618
|
||||
set y 16.119975403493935
|
||||
set z 6.6799998283386177
|
||||
|
||||
# check that vertex with coordinates (x, y, z) is inside the bounding box of f
|
||||
|
||||
boundingstr f xmin ymin zmin xmax ymax zmax
|
||||
|
||||
if {$x < [dval xmin] || $x > [dval xmax] || $y < [dval ymin] || $y > [dval ymax] || $z < [dval zmin] || $z > [dval zmax]} {
|
||||
puts "Error: bounding box works incorrect"
|
||||
}
|
2
tests/lowalgos/end
Normal file
2
tests/lowalgos/end
Normal file
@ -0,0 +1,2 @@
|
||||
# to end a test script
|
||||
puts "TEST COMPLETED"
|
2
tests/lowalgos/grids.list
Normal file
2
tests/lowalgos/grids.list
Normal file
@ -0,0 +1,2 @@
|
||||
001 2dinter
|
||||
002 bnd
|
1
tests/lowalgos/parse.rules
Normal file
1
tests/lowalgos/parse.rules
Normal file
@ -0,0 +1 @@
|
||||
FAILED /\bFaulty\b/ bad shape
|
Loading…
x
Reference in New Issue
Block a user