1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-09-08 14:17:06 +03:00

0025298: New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection

Test cases for issue CR25298
This commit is contained in:
jgv
2014-10-02 13:36:12 +04:00
committed by bugmaster
parent 1c1e319d1e
commit c19dd45ee0
28 changed files with 891 additions and 209 deletions

36
tests/bugs/modalg_5/bug25298_01 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25225_2869_open.brep] a
smallview
display a
fit
if [catch { openoffset resoffset a 1 10 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 193.986
set nb_v_good 4
set nb_e_good 3
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 8
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_02 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25225_2869_open.brep] a
smallview
display a
fit
if [catch { openoffset resoffset a 1 -10 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 159.96
set nb_v_good 3
set nb_e_good 2
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 6
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_03 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25225_2869_open.brep] a
smallview
display a
fit
if [catch { mkoffset resoffset a 1 10 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 416.777
set nb_v_good 7
set nb_e_good 7
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 15
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_04 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25225_2869_closed.brep] a
smallview
display a
fit
if [catch { mkoffset resoffset a 1 -10 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 192.023
set nb_v_good 3
set nb_e_good 3
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 7
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_05 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25225_2869_closed.brep] a
smallview
display a
fit
if [catch { mkoffset resoffset a 1 10 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 403.249
set nb_v_good 4
set nb_e_good 4
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 9
display result
fit
}
set only_screen_axo 1

40
tests/bugs/modalg_5/bug25298_06 Executable file
View File

@@ -0,0 +1,40 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
circle cc 0 0 0 10
trim cc cc pi 3*pi/2
mkedge e1 cc
polyline pp 0 -10 0 -10 -10 0 -10 0 0
wire ww e1 pp
smallview
display ww
fit
if [catch { mkoffset resoffset ww 1 2. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 49.1327
set nb_v_good 5
set nb_e_good 5
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 11
display result
fit
}
set only_screen_axo 1

40
tests/bugs/modalg_5/bug25298_07 Executable file
View File

@@ -0,0 +1,40 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
circle cc 0 0 0 10
trim cc cc pi 3*pi/2
mkedge e1 cc
polyline pp 0 -10 0 -10 -10 0 -10 0 0
wire ww e1 pp
smallview
display ww
fit
if [catch { mkoffset resoffset ww 1 -0.2 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 24.2333
set nb_v_good 3
set nb_e_good 3
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 7
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_08 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline pp 0 0 0 10 0 0 10 10 0 6 10 0 6 15 0 4 15 0 4 10 0 0 10 0 0 0 0
smallview
display pp
fit
if [catch { mkoffset resoffset pp 1 1. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 58
set nb_v_good 8
set nb_e_good 8
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 17
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_09 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline pp 0 0 0 10 0 0 10 10 0 6 10 0 6 15 0 4 15 0 4 10 0 0 10 0 0 0 0
smallview
display pp
fit
if [catch { mkoffset resoffset pp 1 -1. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 42
set nb_v_good 6
set nb_e_good 7
set nb_w_good 2
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 1
set nb_shape_good 16
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_10 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline pp 0 0 0 10 0 0 10 10 0 6 10 0 6 15 0 4 15 0 4 10 0 0 10 0 0 0 0
smallview
display pp
fit
if [catch { mkoffset resoffset pp 1 -0.2 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 48.4
set nb_v_good 8
set nb_e_good 8
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 17
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_11 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline pp 0 0 0 10 0 0 10 10 0 6 10 0 6 15 0 4 15 0 4 10 0 0 10 0 0 0 0
smallview
display pp
fit
if [catch { mkoffset resoffset pp 1 -2. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 24
set nb_v_good 5
set nb_e_good 5
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 11
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_12 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline a 0 0 0 10 0 0 10 20 0 5 5 0 0 20 0 0 0 0
smallview
display a
fit
if [catch { mkoffset resoffset a 1 0.5 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 92.9473
set nb_v_good 5
set nb_e_good 5
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 11
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_13 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline a 0 0 0 10 0 0 10 20 0 5 5 0 0 20 0 0 0 0
smallview
display a
fit
if [catch { mkoffset resoffset a 1 -0.2 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 77.093
set nb_v_good 5
set nb_e_good 5
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 11
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_14 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
polyline a 0 0 0 10 0 0 10 20 0 5 5 0 0 20 0 0 0 0
smallview
display a
fit
if [catch { mkoffset resoffset a 1 -2.5 i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 10
set nb_v_good 6
set nb_e_good 6
set nb_w_good 2
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 1
set nb_shape_good 15
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_15 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25298_Offset_Test.brep] a
smallview
display a
fit
if [catch { mkoffset resoffset a 1 5. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 484.978
set nb_v_good 7
set nb_e_good 7
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 15
display result
fit
}
set only_screen_axo 1

36
tests/bugs/modalg_5/bug25298_16 Executable file
View File

@@ -0,0 +1,36 @@
puts "============"
puts "OCC25298"
puts "============"
puts ""
#######################################################################
# New option of BRepOffsetAPI_MakeOffset algorithm: processing of sharp corners in mode GeomAbs_Intersection
#######################################################################
restore [locate_data_file bug25298_Offset_Test.brep] a
smallview
display a
fit
if [catch { mkoffset resoffset a 1 -5. i } ] {
puts "Error : mkoffset is wrong"
} else {
renamevar resoffset_1 result
set length 409.27
set nb_v_good 7
set nb_e_good 7
set nb_w_good 1
set nb_f_good 0
set nb_sh_good 0
set nb_sol_good 0
set nb_compsol_good 0
set nb_compound_good 0
set nb_shape_good 15
display result
fit
}
set only_screen_axo 1