--- /dev/null
+puts "TODO OCC14846 ALL: Faulty shapes in variables faulty_1 to faulty_"
+
+puts "========"
+puts "OCC14846"
+puts "========"
+puts ""
+###########################################################################
+# ShapeFix_Wireframe::FixWireGaps() works wrong on a shape with seam edge
+###########################################################################
+
+restore [locate_data_file bug14846_Surf_Top.brep] a
+
+checkshape a
+fixwgaps result a
+checkshape result
+
+set bug_info_inp [string trim [lindex [tolerance a] 1]]
+set bug_info_inp [string trim [string range $bug_info_inp [expr {[string last "=" $bug_info_inp] + 1}] [expr {[string length $bug_info_inp] - 1}]]]
+
+set bug_info_out [string trim [lindex [tolerance result] 1]]
+set bug_info_out [string trim [string range $bug_info_out [expr {[string last "=" $bug_info_out] + 1}] [expr {[string length $bug_info_out] - 1}]]]
+
+set tmp_i [string trim [string range $bug_info_inp [expr {[string last "." $bug_info_inp] + 1}] [expr {[string length $bug_info_inp] - 1}]]]
+set tmp_o [string trim [string range $bug_info_out [expr {[string last "=" $bug_info_out] + 1}] [expr {[string length $bug_info_out] - 1}]]]
+
+set bug_info_value 0
+if {[string length $bug_info_inp] < [string length $bug_info_out]} {
+ set bug_info_value [string length $bug_info_inp]
+} else {
+ set bug_info_value [string length $bug_info_out]
+}
+if {$bug_info_value > 8} {
+ set bug_info_value 8
+}
+set bug_info_inp [string trim [string range $bug_info_inp 0 [expr {[string last "." $bug_info_inp] + $bug_info_value}]]]
+set bug_info_out [string trim [string range $bug_info_out 0 [expr {[string last "." $bug_info_out] + $bug_info_value}]]]
+
+if {$bug_info_out > $bug_info_inp} {
+ puts "OCC14846 is reproduced. Tolerance is increased after fixwgaps."
+}
--- /dev/null
+puts "TODO OCC28523 ALL: Error: Bad area of face"
+
+puts "========"
+puts "OCC28523"
+puts "========"
+puts ""
+################################################
+## Fixshape reverses the orientation of the face
+################################################
+
+restore [locate_data_file bug28377_problemface.brep] f2
+
+fixshape newface f2
+
+checkshape newface ff1
+
+set prop [ sprops newface ]
+regexp {Mass\s*:\s*([0-9.e+-]+)} $prop prop_s Area
+
+if { ${Area} <= 0. } {
+ puts "Error: Bad area of face"
+}
--- /dev/null
+puts "TODO OCC28595 ALL: Faulty shapes in variables faulty_1"
+#puts "TODO OCC28595 ALL: Error: bad tolerance of fixshape"
+
+puts "========"
+puts "OCC28595"
+puts "========"
+puts ""
+##########################################################################
+## Shifting 2d curves for non-periodic surfaces leads to incorrect result.
+##########################################################################
+
+restore [locate_data_file bug28595_face.brep] f
+
+fixshape res f
+
+checkshape res
+
+regexp {Tolerance MAX=([-0-9.+eE]+)} [tolerance f] full f_Tolerance
+regexp {Tolerance MAX=([-0-9.+eE]+)} [tolerance res] full res_Tolerance
+
+if { ${res_Tolerance} > ${f_Tolerance} } {
+ puts "Error: bad tolerance of fixshape"
+}
--- /dev/null
+puts "========"
+puts "OCC28768"
+puts "========"
+puts ""
+#############################################
+# ShapeFix slighly corrupts the source face
+#############################################
+
+binrestore [locate_data_file bug28768_f12g.brep] f12g
+fixshape r12g f12g
+
+explode r12g E
+
+smallview +X+Y
+
+# Picture creation: "should be"
+clear
+display r12g_4
+display r12g_6
+fit
+display r12g_5
+xwd $imagedir/${casename}_should_be.png
+
+# Picture creation: "is"
+clear
+display r12g_4
+display r12g_6
+fit
+display r12g_7
+display r12g_3
+xwd $imagedir/${casename}_is.png
--- /dev/null
+puts "========"
+puts "OCC16424"
+puts "========"
+puts ""
+##############################################
+# Exception in reading of attached IGES file
+##############################################
+
+igesread [locate_data_file bug16424_s554_tassello_per_punzone_pos09.igs] a *
+checkshape a
+
+smallview
+clear
+display a
+fit
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file bug26671.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file buc60823.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file BUC60850.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file OCC58a.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file OCC131-7.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file igsBF5.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file OCC22893-thread_22534_boing777.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file ger61337a.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28694 ALL: ERROR: OCC28694 is reproduced."
+
+puts "========"
+puts "OCC28694"
+puts "========"
+puts ""
+###############################################################
+# IGES reader produces too small edge covered by its vertices
+###############################################################
+
+igesbrep [locate_data_file TibTray_Size3.igs] r *
+
+foreach e [explode r e] {
+ if {[lsearch [dump $e] degenerated] == -1 && [validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: OCC28694 is reproduced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "========"
+puts "OCC3936"
+puts "========"
+puts ""
+#################################################################
+# Face on a surface of extrusion is extended after import to IGES
+#################################################################
+
+set File1 [locate_data_file bug3936_tt.igs]
+set File2 ${imagedir}/bug3936_tt1.igs
+file delete -force ${File2}
+
+igesbrep ${File1} a *
+
+brepiges a ${File2}
+
+igesbrep ${File2} a1 *
+
+#
+####
+#
+set area 191477.
+
+set nbshapes_expected "
+Number of shapes in shape
+ EDGE : 4
+ WIRE : 1
+ FACE : 1
+"
+##
+checkprops a -s ${area}
+checkshape a
+checknbshapes a -ref ${nbshapes_expected} -t -m "initial file"
+checkview -display a -2d -path ${imagedir}/${test_image}-initial.png
+##
+checkprops a1 -s ${area}
+checkshape a1
+checknbshapes a1 -ref ${nbshapes_expected} -t -m "importing file"
+checkview -display a1 -2d -path ${imagedir}/${test_image}-importing.png
--- /dev/null
+puts "======="
+puts "CR28194"
+puts "======="
+puts ""
+#########################################################
+# BRepMesh - Standard_OutOfRange exception on valid shape
+#########################################################
+
+restore [locate_data_file bug28194.brep] a
+
+incmesh a 0.0005
+
+checktrinfo a -tri -nod
+
+checkview -display a -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28247 ALL: Error: Effect of minSize parameter of BRepMesh_IncrementalMesh seems to be too strong"
+
+puts "========="
+puts "OCC28247"
+puts "========="
+puts ""
+################################################################################
+# Effect of minSize parameter of BRepMesh_IncrementalMesh seems to be too strong
+################################################################################
+
+restore [locate_data_file bug28247_face.brep] f
+whatis f
+tolerance f
+
+vinit
+vsetdispmode 1
+vdisplay f
+vfit
+
+tclean f
+incmesh f 0.59
+trinfo f
+vdisplay f
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-1.png
+
+tclean f
+incmesh f 0.59 -a 11.45
+set tri_info_1 [trinfo f]
+regexp { +([-0-9.+eE]+) +triangles} $tri_info_1 full tri_1
+regexp { +([-0-9.+eE]+) +nodes} $tri_info_1 full nod_1
+vdisplay f
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-2.png
+
+tclean f
+incmesh f 0.59 -a 11.45 -min 0.035
+set tri_info_2 [trinfo f]
+regexp { +([-0-9.+eE]+) +triangles} $tri_info_2 full tri_2
+regexp { +([-0-9.+eE]+) +nodes} $tri_info_2 full nod_2
+vdisplay f
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-3.png
+
+if { ${tri_1} > ${tri_2} } {
+ puts "Error: Effect of minSize parameter of BRepMesh_IncrementalMesh seems to be too strong"
+}
--- /dev/null
+puts "========"
+puts "OCC28379"
+puts "========"
+puts ""
+###########################################
+# BRepMesh produces mangled mesh for a cone
+###########################################
+
+pcone s 0 0.1 1
+incmesh s 1e-3
+
+vinit
+vsetdispmode 1
+vdisplay s
+vfit
+
+vleft
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-left.png
+
+vright
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-right.png
+
+vfront
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-front.png
+
+vback
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-back.png
--- /dev/null
+puts "TODO CR28500 ALL: Artifact in shaded view of the shape"
+
+puts "======="
+puts "CR28500"
+puts "======="
+puts ""
+######################################
+# Artifact in shaded view of the shape
+######################################
+
+restore [locate_data_file bug28500_shape_mesh_artifact.brep] a
+
+incmesh a 0.01
+
+vinit
+vsetdispmode 1
+vdisplay a
+vfit
+
+set x 150
+set y 150
+if { [checkcolor $x $y 0 1 0] == 1 } {
+ puts "Error: Artifact in shaded view of the shape"
+}
+
+checkview -screenshot -3d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28719 ALL: ERROR: OCC28719 is reproduced."
+
+puts "========"
+puts "OCC28719"
+puts "========"
+puts ""
+###################################
+# Display issue for special model
+###################################
+
+restore [locate_data_file bug28719_display_issue.brep] result
+
+vinit
+vdisplay result
+vsetdispmode result 1
+vfit
+
+if {[string trim [vreadpixel 255 169 name]] == "GRAY75 1"} {
+ puts "ERROR: OCC28719 is reproduced. Nontriangulated faces have been detected."
+}
+if {[string trim [vreadpixel 133 241 name]] == "GRAY75 1"} {
+ puts "ERROR: OCC28719 is reproduced. Nontriangulated faces have been detected."
+}
+
+checkview -screenshot -3d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "========================"
-puts " BUC60866 "
-puts " OCC77 "
-puts "========================"
-puts ""
-######################################################
-# The BRepFill_Pipe fails
-######################################################
-
-restore [locate_data_file buc60866a.rle] f
-checkshape f
-
-restore [locate_data_file buc60866b.rle] w
-checkshape w
-
-pipe result w f
-
-checkprops result -s 1.12048e+07
-checkshape result
-checkview -display result -2d -path ${imagedir}/${test_image}.png
-
-
--- /dev/null
+puts "TODO OCC77 ALL: Error : The area of result shape is"
+
+puts "====="
+puts "OCC77"
+puts "====="
+puts ""
+####################################
+# BUC60866. The BRepFill_Pipe fails.
+####################################
+
+restore [locate_data_file buc60866a.rle] Section
+restore [locate_data_file buc60866b.rle] PathBad
+
+set area 1.12049e+07
+
+set nbshapes_expected "
+Number of shapes in shape
+ VERTEX : 15
+ EDGE : 22
+ WIRE : 8
+ FACE : 8
+ SHELL : 2
+ SOLID : 0
+ COMPSOLID : 0
+ COMPOUND : 1
+ SHAPE : 56
+"
+
+smallview
+display Section
+display PathBad
+fit
+
+
+#
+# Mode = 0 - CorrectedFrenet
+#
+pipe result_0 PathBad Section
+
+checkshape result_0
+
+checkprops result_0 -s ${area}
+
+checknbshapes result_0 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_0]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 0"
+}
+
+donly result_0
+checkview -screenshot -2d -path ${imagedir}/${test_image}_0.png
+
+
+#
+# Mode = 1 - Frenet
+#
+set Mode 1
+pipe result_1 PathBad Section ${Mode}
+
+checkshape result_1
+
+checkprops result_1 -s ${area}
+
+checknbshapes result_1 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_1]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 1"
+}
+
+donly result_1
+checkview -screenshot -2d -path ${imagedir}/${test_image}_1.png
+
+
+#####
+##### Approx - force C1-approximation if result is C0
+#####
+set Approx 1
+set Mode 1
+pipe result_1_a PathBad Section ${Mode} ${Approx}
+
+checkshape result_1_a
+
+checkprops result_1_a -s ${area}
+
+checknbshapes result_1_a -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_1_a]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 1a"
+}
+
+donly result_1_a
+checkview -screenshot -2d -path ${imagedir}/${test_image}_1_a.png
+
+
+#
+# Mode = 2 - DiscreteTrihedron
+#
+set Mode 2
+pipe result_2 PathBad Section ${Mode}
+
+checkshape result_2
+
+checkprops result_2 -s ${area}
+
+checknbshapes result_2 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_2]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 2"
+}
+
+donly result_2
+checkview -screenshot -2d -path ${imagedir}/${test_image}_2.png
+
+
+#####
+##### Approx - force C1-approximation if result is C0
+#####
+set Approx 1
+set Mode 2
+pipe result_2_a PathBad Section ${Mode} ${Approx}
+
+checkshape result_2_a
+
+checkprops result_2_a -s ${area}
+
+checknbshapes result_2_a -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_2_a]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 2a"
+}
+
+donly result_2_a
+checkview -screenshot -2d -path ${imagedir}/${test_image}_2_a.png
--- /dev/null
+puts "TODO OCC77 ALL: Error : The area of result shape is"
+
+puts "====="
+puts "OCC77"
+puts "====="
+puts ""
+####################################
+# BUC60866. The BRepFill_Pipe fails.
+####################################
+
+restore [locate_data_file buc60866a.rle] Section
+restore [locate_data_file buc60866b.rle] PathBad
+
+reverse PathBad
+
+set area 1.12049e+07
+
+set nbshapes_expected "
+Number of shapes in shape
+ VERTEX : 15
+ EDGE : 22
+ WIRE : 8
+ FACE : 8
+ SHELL : 2
+ SOLID : 0
+ COMPSOLID : 0
+ COMPOUND : 1
+ SHAPE : 56
+"
+
+smallview
+display Section
+display PathBad
+fit
+
+
+#
+# Mode = 0 - CorrectedFrenet
+#
+pipe result_0 PathBad Section
+
+checkshape result_0
+
+checkprops result_0 -s ${area}
+
+checknbshapes result_0 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_0]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 0"
+}
+
+donly result_0
+checkview -screenshot -2d -path ${imagedir}/${test_image}_0.png
+
+
+#
+# Mode = 1 - Frenet
+#
+set Mode 1
+pipe result_1 PathBad Section ${Mode}
+
+checkshape result_1
+
+checkprops result_1 -s ${area}
+
+checknbshapes result_1 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_1]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 1"
+}
+
+donly result_1
+checkview -screenshot -2d -path ${imagedir}/${test_image}_1.png
+
+
+#####
+##### Approx - force C1-approximation if result is C0
+#####
+set Approx 1
+set Mode 1
+pipe result_1_a PathBad Section ${Mode} ${Approx}
+
+checkshape result_1_a
+
+checkprops result_1_a -s ${area}
+
+checknbshapes result_1_a -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_1_a]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 1a"
+}
+
+donly result_1_a
+checkview -screenshot -2d -path ${imagedir}/${test_image}_1_a.png
+
+
+#
+# Mode = 2 - DiscreteTrihedron
+#
+set Mode 2
+pipe result_2 PathBad Section ${Mode}
+
+checkshape result_2
+
+checkprops result_2 -s ${area}
+
+checknbshapes result_2 -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_2]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 2"
+}
+
+donly result_2
+checkview -screenshot -2d -path ${imagedir}/${test_image}_2.png
+
+
+#####
+##### Approx - force C1-approximation if result is C0
+#####
+set Approx 1
+set Mode 2
+pipe result_2_a PathBad Section ${Mode} ${Approx}
+
+checkshape result_2_a
+
+checkprops result_2_a -s ${area}
+
+checknbshapes result_2_a -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result_2_a]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : The BRepFill_Pipe fails, 2a"
+}
+
+donly result_2_a
+checkview -screenshot -2d -path ${imagedir}/${test_image}_2_a.png
-puts "============"
-puts "BUC60875"
+puts "====="
puts "OCC78"
-puts "============"
+puts "====="
puts ""
-###############################
-## Pipe is created incorrectly on two wires
-###############################
-
-#datadir /disk4/QA/hotline/GRIDS/chl/data
-restore [locate_data_file BUC60875_wire.brep] w
-restore [locate_data_file BUC60875_profile.brep] p
-checkshape w
-checkshape p
-
-pipe result w p
-checkprops result -s 10191.8
+#####################################################
+# BUC60875. Pipe is created incorrectly on two wires.
+#####################################################
+
+restore [locate_data_file BUC60875_wire.brep] wire
+restore [locate_data_file BUC60875_profile.brep] profile
+
+checkshape wire
+checkshape profile
+
+set area 10225.7
+
+set nbshapes_expected "
+Number of shapes in shape
+ VERTEX : 27
+ EDGE : 42
+ WIRE : 16
+ FACE : 16
+ SHELL : 2
+ SOLID : 0
+ COMPSOLID : 0
+ COMPOUND : 1
+ SHAPE : 104
+"
+
+pipe result wire profile
+
checkshape result
+
+checkprops result -s ${area}
+
+checknbshapes result -ref ${nbshapes_expected} -t -m "Pipe"
+
+set info [bopcheck result]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : Pipe is created incorrectly on two wires"
+}
+
checkview -display result -2d -path ${imagedir}/${test_image}.png
-puts "============"
-puts "BUC60908"
+puts "TODO OCC82 ALL: Error : Incomplete section of shell by plane"
+
+puts "====="
puts "OCC82"
-puts "============"
+puts "====="
puts ""
-###############################
-## Incomplete section of shell by plane
-###############################
+#################################################
+# BUC60908. Incomplete section of shell by plane.
+#################################################
+
+restore [locate_data_file BUC60907_px1.rle] sh
-restore [locate_data_file BUC60907_px1.rle] sh
checkshape sh
+set length 113.703
+
+set nbshapes_expected "
+Number of shapes in shape
+ VERTEX : 44
+ EDGE : 41
+"
+
plane f 0 14.8053 0 0 1 0
mkface f f
-bsection result sh f
-set nb_info [nbshapes result]
-regexp {VERTEX +: +([-0-9.+eE]+)} $nb_info full nb_verices
-regexp {EDGE +: +([-0-9.+eE]+)} $nb_info full nb_edges
+section result sh f
+
+checkshape result
-set nnv [expr $nb_verices-1]
+checkprops result -l ${length}
-puts "VERTEX : $nb_verices, EDGE : $nb_edges"
+checknbshapes result -ref ${nbshapes_expected} -t -m "Section"
-if { $nnv > $nb_edges } {
- puts "Surplus of vertices, Faulty section"
-} else {
- puts "Number of vertices correspond edges: OK"
+set info [bopcheck result]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : Incomplete section of shell by plane"
}
-checkprops result -l 113.703
-checkshape result
-checksection result
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+checkview -display result -with sh -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "====="
+puts "OCC82"
+puts "====="
+puts ""
+#################################################
+# BUC60908. Incomplete section of shell by plane.
+#################################################
+
+restore [locate_data_file BUC60907_px1.rle] sh
+
+checkshape sh
+
+set length 113.703
+
+set nbshapes_expected "
+Number of shapes in shape
+ VERTEX : 42
+ EDGE : 41
+"
+
+plane f 0 14.8053 0 0 1 0
+mkface f f
+
+bsection result sh f
+
+checkshape result
+
+checkprops result -l ${length}
+
+checknbshapes result -ref ${nbshapes_expected} -t -m "Section"
+
+set info [bopcheck result]
+if { [regexp "This shape seems to be OK" ${info}] != 1 } {
+ puts "Error : Incomplete section of shell by plane"
+}
+
+checkview -display result -with sh -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC10377"
+puts "========"
+puts ""
+#############################################################
+# Incorrect fuse result when objects tangent by planar face
+#############################################################
+
+restore [locate_data_file bug10377_shapes.brep] c
+
+explode c
+bfuse result c_1 c_2
+checkshape result
+
+checknbshapes result -shell 1 -face 20 -wire 20
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC10377"
+puts "========"
+puts ""
+#############################################################
+# Incorrect fuse result when objects tangent by planar face
+#############################################################
+
+restore [locate_data_file bug10377_shapes2.brep] c
+
+explode c
+bfuse result c_1 c_2
+checkshape result
+
+checknbshapes result -shell 1 -face 26 -wire 26
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC13565"
+puts "========"
+puts ""
+########################################
+# Incorrect result of Common operation
+########################################
+
+restore [locate_data_file bug13565_A.brep] a
+restore [locate_data_file bug13565_B.brep] b
+
+bcommon result a b
+checkshape result
+
+checknbshapes result -shell 1 -face 17 -wire 17
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC13565"
+puts "========"
+puts ""
+########################################
+# Incorrect result of Common operation
+########################################
+
+restore [locate_data_file bug13565_A.brep] a
+restore [locate_data_file bug13565_B.brep] b
+
+bcommon result b a
+checkshape result
+
+checknbshapes result -shell 1 -face 17 -wire 17
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC13566"
+puts "========"
+puts ""
+#################################################################
+# Incorrect result of Extrema between a large circle and a line
+#################################################################
+
+restore [locate_data_file bug13566_line.brep] l
+restore [locate_data_file bug13566_circle.brep] c
+
+distmini d l c
+
+if {[dval d_val] > 0.01} {
+ puts "ERROR: OCC13566 is reproduced. Minimum distance is too large."
+}
--- /dev/null
+puts "========"
+puts "OCC24632"
+puts "========"
+puts ""
+###############################################################
+# Artifacts during Boolean cut operation on neighboring parts
+###############################################################
+
+restore [locate_data_file bug24632_general.brep] general
+restore [locate_data_file bug24632_cramp.brep] cramp
+restore [locate_data_file bug24632_cut_1.brep] cut_1
+restore [locate_data_file bug24632_cut_2.brep] cut_2
+
+bclearobjects
+bcleartools
+baddobjects general cramp
+bfillds
+bbuild beam
+checkshape beam
+
+bop beam cut_1
+bopcut beam_1
+checkshape beam_1
+
+bop beam_1 cut_2
+bopcut result
+checkshape result
+
+checknbshapes result -solid 2 -shell 2 -face 32 -wire 39
+checkprops result -v 5.40325e+7
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC24632"
+puts "========"
+puts ""
+###############################################################
+# Artifacts during Boolean cut operation on neighboring parts
+###############################################################
+
+restore [locate_data_file bug24632_general.brep] general
+restore [locate_data_file bug24632_fitting.brep] fitting
+restore [locate_data_file bug24632_cramp.brep] cramp
+restore [locate_data_file bug24632_cut_1.brep] cut_1
+restore [locate_data_file bug24632_cut_2.brep] cut_2
+
+explode fitting so
+bclearobjects
+bcleartools
+baddobjects fitting_1 fitting_2
+bfillds
+bbuild fitting_12
+checkshape fitting_12
+
+bclearobjects
+bcleartools
+baddobjects general fitting_12
+bfillds
+bbuild beam
+checkshape beam
+
+bclearobjects
+bcleartools
+baddobjects beam cramp
+bfillds
+bbuild beam_1
+checkshape beam_1
+
+bop beam_1 cut_1
+bopcut beam_2
+checkshape beam_2
+
+bop beam_2 cut_2
+bopcut result
+checkshape result
+
+checknbshapes result -solid 4 -shell 4 -face 64 -wire 73
+checkprops result -v 1.61677e+8
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC24632"
+puts "========"
+puts ""
+###############################################################
+# Artifacts during Boolean cut operation on neighboring parts
+###############################################################
+
+box b1 10 10 10
+
+box b2 10 0 0 10 10 10
+
+plane p -10 5 5 1 0 0
+pcylinder cut p 2.5 40
+checkshape cut
+
+bclearobjects
+bcleartools
+baddobjects b1 b2
+bfillds
+bbuild c
+checkshape c
+
+bop c cut
+bopcut result
+checkshape result
+
+checknbshapes result -solid 2 -shell 2 -face 13 -wire 16
+checkprops result -v 1607.3
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "TODO OCC27160 ALL: Error: Weird results of the pipe algorithm"
-
-puts "========"
-puts "OCC27160"
-puts "========"
-puts ""
-#####################################
-# Weird results of the pipe algorithm
-#####################################
-
-cpulimit 3000
-
-smallview
-
-restore [locate_data_file bug27160_path.rle] p
-fit
-checkview -screenshot -2d -path ${imagedir}/${test_image}-path.png
-
-tuyau r p 0.2
-fit
-checkview -screenshot -2d -path ${imagedir}/${test_image}-fit.png
-
-clear r
-
-mkface f r
-fit
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}-f.png
-
-set Log [bopcheck f]
-if {[regexp "This shape seems to be OK" ${Log}] != 1} {
- puts "Error: Weird results of the pipe algorithm"
-}
--- /dev/null
+puts "TODO OCC28108 ALL: Faulty shapes in variables faulty_1 to faulty_"
+
+puts "========"
+puts "OCC28108"
+puts "========"
+puts ""
+######################################
+# Sweep fails in "Right Corner" mode
+######################################
+
+restore [locate_data_file bug28108_sweep.brep] sweep
+
+explode sweep w
+mksweep sweep_2
+addsweep sweep_1
+buildsweep result -C
+
+checkshape result
--- /dev/null
+puts "TODO OCC28167 ALL: Error: Fillet has strange form at its end"
+
+puts "========"
+puts "OCC28167"
+puts "========"
+puts ""
+#####################################
+# Fillet has strange form at its end
+#####################################
+
+restore [locate_data_file bug28167_solid.brep] s
+
+explode s E
+
+fillet r s 1 s_3
+
+explode r F
+explode r_6 E
+renamevar r_6_1 res
+
+regexp {Mass +: +([-0-9.+eE]+)} [lprops res] full length_r_6_1
+
+set expected_length 1.31899
+set toleranse 1.e-4
+if {[expr abs(${length_r_6_1} - ${expected_length})] <= ${toleranse}} {
+ puts "Error: Fillet has strange form at its end"
+}
+
+checkview -display r_6 -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC28168"
+puts "========"
+puts ""
+##############################################
+# Exception is raised during Boolean operation
+##############################################
+
+restore [locate_data_file bug28168_shapes.brep] b
+
+explode b
+
+bclearobjects
+bcleartools
+baddobjects b_1
+baddtools b_2
+
+bfillds
--- /dev/null
+puts "TODO OCC28200 ALL: Faulty shapes in variables faulty_1 to"
+
+puts "========"
+puts "OCC28200"
+puts "========"
+puts ""
+#############################################
+# Invalid topology of the general fuse result
+#############################################
+
+restore [locate_data_file bug28200_sh.brep] sh
+sewing sh sh 1.0
+
+restore [locate_data_file bug28200_cc.brep] c
+
+# Input data check
+checkshape sh
+checkshape c
+
+# Result construction
+bclearobjects
+bcleartools
+baddobjects sh
+baddtools c
+bfuzzyvalue 1.0
+bfillds
+bbuild result
+
+checkshape result
+
+smallview
+donly result
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}_1.png
+
+left
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}_2.png
+
+donly faulty_1 faulty_2 faulty_3 faulty_4 faulty_5 faulty_6 faulty_7 faulty_8
+checkview -screenshot -2d -path ${imagedir}/${test_image}_3.png
--- /dev/null
+puts "TODO OCC28216 ALL: Error : bopcommon is WRONG"
+
+puts "============"
+puts "OCC28216"
+puts "============"
+puts ""
+#####################################################################################################
+# Intersection of a face and a solid is broken up leading to empty result of Boolean common operation
+#####################################################################################################
+
+restore [locate_data_file bug28216_initSurf.brep] s
+restore [locate_data_file bug28216_solid.brep] o
+
+bop s o
+
+bopsection r_section
+checknbshapes r_section -vertex 4 -edge 3 -m "bopsection"
+bopcheck r_section
+
+bopcommon r_common
+checknbshapes r_common -vertex 4 -edge 3 -m "bopcommon"
+bopcheck r_common
+
+checkview -display r_section -2d -path ${imagedir}/${test_image}-section.png
+checkview -display r_common -2d -path ${imagedir}/${test_image}-common.png
--- /dev/null
+puts "========"
+puts "OCC28245"
+puts "========"
+puts ""
+#################################################################################################
+# Result of Cells Builder algorithm becomes invalid after removal of internal boundaries on faces
+#################################################################################################
+
+circle c1 0 0 0 0 0 1 10
+circle c2 10 0 0 0 0 1 10
+circle c3 5 9 0 0 0 1 10
+
+mkedge e1 c1
+mkedge e2 c2
+mkedge e3 c3
+
+wire w1 e1
+wire w2 e2
+wire w3 e3
+
+mkplane f1 w1
+mkplane f2 w2
+mkplane f3 w3
+
+bclearobjects
+bcleartools
+baddobjects f1 f2 f3
+bfillds
+bcbuild rx
+
+bcadd res f1 1 -m 1
+bcadd res f2 1 f3 0 -m 1
+bcadd res f3 1 f1 0 -m 2
+
+bopcheck res
+if {![regexp "This shape seems to be OK" [bopcheck res]]} {
+ puts "Error: Result of Cells Builder algorithm is invalid"
+}
+checkview -display res -2d -path ${imagedir}/${test_image}-1.png
+
+bcremoveint res
+if {![regexp "This shape seems to be OK" [bopcheck res]]} {
+ puts "Error: Result of Cells Builder algorithm becomes invalid after removal of internal boundaries on faces"
+}
+checkview -display res -2d -path ${imagedir}/${test_image}-2.png
--- /dev/null
+puts "TODO OCC28274 ALL: Error: BOPAlgo_MakerVolume fails to create solid"
+
+puts "========"
+puts "OCC28274"
+puts "========"
+puts ""
+######################################################
+# BOPAlgo_MakerVolume fails to create solid
+######################################################
+
+restore [locate_data_file bug28274_tmp.brep] a
+
+bnondestructive 1
+
+set Log [eval mkvolume result [explode a f] ]
+
+if {[regexp "Warning" ${Log}] == 1} {
+ puts "Error: BOPAlgo_MakerVolume fails to create solid"
+}
+
+checkshape result
+
+bopcheck result
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC28279"
+puts "========"
+puts ""
+###########################################################################################################
+# Greater oscillations and higher degree of resulting B-Spline in cylinder-cylinder intersections in 7.1.0
+###########################################################################################################
+
+restore [locate_data_file bug28279_surface1_draw.draw] s1
+restore [locate_data_file bug28279_surface2_draw.draw] s2
+
+intersect result s1 s2
+
+smallview
+
+point p121 -2.20000000000914, 4.42587047983305, 2.00000000001213
+point p11 -2.20245354854755, 4.52573922818428, 1.82990686981508
+donly p121 p11
+fit
+clear p121 p11
+
+display result_1 result_2 s1 s2
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28354 ALL: Error: Filleting destroys shape if the filleted edge touches a seam edge"
+
+puts "============"
+puts "OCC28354"
+puts "============"
+puts ""
+###################################################################
+# Filleting destroys shape if the filleted edge touches a seam edge
+###################################################################
+
+#pcylinder cylinder 4 8
+#box box -5 -8 4 10 10 10
+#
+#bcut res cylinder box
+#
+
+restore [locate_data_file bug28354.brep] res
+
+explode res e
+
+blend result_1 res 1.5 res_9
+set Log_1 [whatis result_1]
+if {[regexp "shape" ${Log_1}] != 1} {
+ puts "Error: Filleting destroys shape"
+}
+checkview -display result_1 -2d -path ${imagedir}/${test_image}-1.png
+
+catch {blend result_2 res 2.2 res_9}
+set Log_2 [whatis result_2]
+if {[regexp "shape" ${Log_2}] != 1} {
+ puts "Error: Filleting destroys shape if the filleted edge touches a seam edge"
+}
+checkview -display result_2 -2d -path ${imagedir}/${test_image}-2.png
--- /dev/null
+puts "TODO OCC28366 ALL: Error: BOP"
+
+puts "============"
+puts "OCC28366"
+puts "============"
+puts ""
+#############################################
+# BOP Common fails with solid and planar face
+#############################################
+
+pload XDE
+
+stepread [locate_data_file bug28366_fuselage.stp] a *
+renamevar a_1 a
+
+# Sew all the faces and make a solid.
+explode a f
+sewing shell 1.0e-6 a_1 a_2 a_3 a_4 a_5 a_6 a_7 a_8
+mkvolume fuselage shell
+
+# Make a xy-plane at the origin.
+plane pln
+mkface face pln
+
+# Try a bcommon
+set Log_1 [bcommon common face fuselage]
+if {[regexp "Warning" ${Log_1}] == 1} {
+ puts "Error: BOP Common fails with solid and planar face"
+}
+set Log [bopcheck common]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BOP Common fails with solid and planar face"
+}
+checkview -display common -2d -path ${imagedir}/${test_image}_common.png
+
+# Try bsection
+set Log_2 [bsection section face fuselage]
+if {[regexp "Warning" ${Log_1}] == 1} {
+ puts "Error: BOP Section fails with solid and planar face"
+}
+set Log [bopcheck section]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BOP Section fails with solid and planar face"
+}
--- /dev/null
+puts "TODO OCC28393 ALL: Error : The area of result shape is"
+puts "TODO OCC28393 ALL: Error : The volume of result shape is"
+puts "TODO OCC28393 ALL: Error : is WRONG because number of"
+
+puts "========"
+puts "OCC28393"
+puts "========"
+puts ""
+###################################
+# Boolean cut produce wrong result.
+###################################
+
+restore [locate_data_file bug28393_o.brep] o
+restore [locate_data_file bug28393_t.brep] t
+
+bcut result o t
+
+checkshape result
+bopcheck result
+
+checkprops result -s 70266.5 -v 979408
+checknbshapes result -solid 1 -shell 1 -face 42 -wire 44
+
+checkview -display result -2d -path ${imagedir}/${test_image}-result.png
--- /dev/null
+puts "========"
+puts "OCC28393"
+puts "========"
+puts ""
+###################################
+# Boolean cut produce wrong result.
+###################################
+
+restore [locate_data_file bug28393_o2.brep] o
+restore [locate_data_file bug28393_t2.brep] t
+
+bcut result o t
+
+checkshape result
+bopcheck result
+
+checkprops result -s 216.264 -v 238.204
+checknbshapes result -solid 1 -shell 1 -face 12 -wire 12
+
+checkview -display result -2d -path ${imagedir}/${test_image}-result.png
--- /dev/null
+puts "TODO OCC28402 ALL: Error: calculation of properties of complex compounds is slow"
+
+puts "========"
+puts "OCC28402"
+puts "========"
+puts ""
+####################################################################
+# Modeling - calculation of properties of complex compounds is slow
+####################################################################
+
+restore [locate_data_file bug28402_hugeassembly.brep] a
+
+# just show that shape contains just one solid (box)
+nbshapes a
+
+# now calculate properties
+chrono s restart
+vprops a
+chrono s stop counter "CPU vprops compounds"
+
+# now calculate properties simple box
+box b 100 100 100
+chrono s_box restart
+vprops b
+chrono s_box stop counter "CPU vprops box"
+
+regexp {Elapsed time: +([-0-9.+eE]+) Hours +([-0-9.+eE]+) Minutes +([-0-9.+eE]+) Seconds} [dchrono s show] full a_Hours a_Minutes a_Seconds
+regexp {Elapsed time: +([-0-9.+eE]+) Hours +([-0-9.+eE]+) Minutes +([-0-9.+eE]+) Seconds} [dchrono s_box show] full b_Hours b_Minutes b_Seconds
+
+set a_Time [expr ${a_Hours}*60.*60. + ${a_Minutes}*60. + ${a_Seconds} ]
+set b_Time [expr ${b_Hours}*60.*60. + ${b_Minutes}*60. + ${b_Seconds} ]
+
+if { [expr ${a_Time} / ${b_Time}] > 100. } {
+ puts "Error: calculation of properties of complex compounds is slow"
+}
--- /dev/null
+puts "TODO 0028406 ALL: Error: MaxTolerance"
+
+puts "======="
+puts "0028406"
+puts "======="
+puts ""
+#######################################################
+# High tolerances after boolean operation on OCCT 6.9.1
+#######################################################
+
+restore [locate_data_file bug28406_ar_shape_to_cuts.brep] b1
+restore [locate_data_file bug28406_ar_cutting_shapes.brep] b2
+
+explode b2 f
+
+set log_1 [bopcurves b1 b2_1 -2d]
+regexp {Tolerance Reached=([-0-9.+eE]+)} $log_1 full tol_reached_1
+
+set log_2 [bopcurves b1 b2_7 -2d]
+regexp {Tolerance Reached=([-0-9.+eE]+)} $log_2 full tol_reached_2
+
+set log_3 [maxtolerance b2]
+regexp { +Face +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $log_3 full MaxFaceTolerance
+
+
+set ToleranceReached-6-9-1_1 0.044936986074371126
+set ToleranceReached-6-9-1_2 0.024455156919182791
+set tol_rel_MaxTol 0.0001
+
+checkreal "MaxTolerance 2_1 " ${tol_reached_1} ${ToleranceReached-6-9-1_1} ${MaxFaceTolerance} ${tol_rel_MaxTol}
+checkreal "MaxTolerance 2_7 " ${tol_reached_2} ${ToleranceReached-6-9-1_2} ${MaxFaceTolerance} ${tol_rel_MaxTol}
--- /dev/null
+puts "TODO OCC28485 ALL: Faulty shapes in variables faulty_1 to"
+
+puts "========"
+puts "OCC28485"
+puts "========"
+puts ""
+##################################################################################
+# Fuse of two shapes using gluing and non-destructive options gives invalid result
+##################################################################################
+
+restore [locate_data_file bug28485_parts.brep] a
+explode a
+
+bnondestructive 1
+brunparallel 1
+bfuzzyvalue 0
+bglue 1
+
+bclearobjects
+bcleartools
+baddobjects a_1
+baddtools a_2
+bfillds
+bbop result 1
+
+checkshape result
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28544 ALL: Error : T="
+
+puts "========"
+puts "OCC28544"
+puts "========"
+puts ""
+##################################################################
+# Big tolerance value is returned by Implicit-parametric algorithm
+##################################################################
+
+restore [locate_data_file bug24094_face.brep] b1
+
+mksurface s1 b1
+plane s2 183.6 0 0 1 0 0 0 1 0
+
+# B-spline + Plane
+intersect ii s1 s2
+bounds ii u1 u2
+xdistcs ii s1 u1 u2 10 2.0e-7
--- /dev/null
+puts "TODO OCC28544 ALL: Error: Big tolerance value is returned by Implicit-parametric algorithm"
+
+puts "========"
+puts "OCC28544"
+puts "========"
+puts ""
+##################################################################
+# Big tolerance value is returned by Implicit-parametric algorithm
+##################################################################
+
+restore [locate_data_file heal-Face1.rle] b1
+restore [locate_data_file Plan.rle] b2
+
+set log_1 [bopcurves b1 b2 -2d]
+regexp {Tolerance Reached=([-0-9.+eE]+)} $log_1 full tol_reached
+
+set log_2 [maxtolerance b1]
+regexp { +Face +: +Min +([-0-9.+eE]+) +Max +([-0-9.+eE]+)} $log_2 full MinFaceTolerance MaxFaceTolerance
+
+if { ${tol_reached} > ${MaxFaceTolerance} } {
+ puts "Error: Big tolerance value is returned by Implicit-parametric algorithm"
+}
--- /dev/null
+puts "TODO OCC28571 ALL: Error: BRepOffsetAPI_MakeOffset build invalid wire"
+
+puts "========"
+puts "OCC28571"
+puts "========"
+puts ""
+#############################################
+# BRepOffsetAPI_MakeOffset build invalid wire
+#############################################
+
+restore [locate_data_file bug28571_inputwire.brep] w
+
+mkoffset result w 1 1 a
+
+set Log [bopcheck result_1]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BRepOffsetAPI_MakeOffset build invalid wire"
+}
+
+regexp {nb alone Vertices : ([-0-9.+eE]+)} [checksection result_1] full nbv
+if { $nbv != 0 } {
+ puts "Error : There are alone Vertices"
+}
+
+top
+donly w result_1
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28571 ALL: Error: BRepOffsetAPI_MakeOffset build invalid wire"
+puts "TODO OCC28571 ALL: Error : There are alone Vertices"
+
+puts "========"
+puts "OCC28571"
+puts "========"
+puts ""
+#############################################
+# BRepOffsetAPI_MakeOffset build invalid wire
+#############################################
+
+restore [locate_data_file bug28571_inputwire.brep] w
+
+openoffset result w 1 1 a
+
+set Log [bopcheck result_1]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BRepOffsetAPI_MakeOffset build invalid wire"
+}
+
+regexp {nb alone Vertices : ([-0-9.+eE]+)} [checksection result_1] full nbv
+if { $nbv != 0 } {
+ puts "Error : There are alone Vertices"
+}
+
+top
+donly w result_1
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC28572 ALL: Faulty shapes in variables faulty_1"
+
+puts "========"
+puts "OCC28572"
+puts "========"
+puts ""
+####################################
+# Wrong result of the mkface command
+####################################
+
+restore [locate_data_file bug28572_m.brep] m
+
+mksurface s1 m
+
+explode m W
+
+mkface f1 s1 m_2
+checkshape f1
+
+
+mkface f2 s1 m_3
+checkshape f2
--- /dev/null
+puts "TODO OCC28572 ALL: Faulty shapes in variables faulty_1"
+
+puts "========"
+puts "OCC28572"
+puts "========"
+puts ""
+####################################
+# Wrong result of the mkface command
+####################################
+
+restore [locate_data_file bug28572_m.brep] f
+
+mksurface s1 f
+
+explode f W
+
+mkface f1 s1 f_2
+checkshape f1
--- /dev/null
+puts "TODO OCC28596 ALL: Error: Erroneous fillet"
+
+puts "========"
+puts "OCC28596"
+puts "========"
+puts ""
+##################
+# Erroneous fillet
+##################
+
+restore [locate_data_file bug28596_fil.brep] f
+
+explode f e
+fillet result f 0.05 f_4
+
+checkshape result
+
+set Log [bopcheck result]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: Erroneous fillet"
+}
+
+vinit
+vdisplay result
+vviewparams -scale 702.276 -proj -0.67842 -0.368345 -0.635663 -up -0.730989 0.424987 0.533892 -at 0.191139 0.100954 0.167229 -eye -4.57791 -2.48838 -4.30125
+
+checkview -screenshot -3d -path ${imagedir}/${test_image}-w.png
+
+vsetdispmode 1
+vselect 100 100
+checkview -screenshot -3d -path ${imagedir}/${test_image}-s.png
--- /dev/null
+puts "========"
+puts "OCC28596"
+puts "========"
+puts ""
+##################
+# Erroneous fillet
+##################
+
+restore [locate_data_file bug28596_fil.brep] f
+
+explode f e
+fillet result f 0.04 f_4
+
+checkshape result
+
+set Log [bopcheck result]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: Erroneous fillet"
+}
+
+vinit
+vdisplay result
+vviewparams -scale 702.276 -proj -0.67842 -0.368345 -0.635663 -up -0.730989 0.424987 0.533892 -at 0.191139 0.100954 0.167229 -eye -4.57791 -2.48838 -4.30125
+
+checkview -screenshot -3d -path ${imagedir}/${test_image}-w.png
+
+vsetdispmode 1
+vselect 100 100
+checkview -screenshot -3d -path ${imagedir}/${test_image}-s.png
--- /dev/null
+puts "TODO OCC28640 ALL: Faulty shapes in variables faulty_1"
+
+puts "========"
+puts "OCC28640"
+puts "========"
+puts ""
+##############################################
+# BRepBuilderAPI_Transform build invalid shape
+##############################################
+
+restore [locate_data_file bug28640_origin_copy.brep] a
+
+smallview
+display a
+front
+fit
+
+vinit
+vsetdispmode 1
+vdisplay a
+vfront
+vfit
+
+#
+
+tmirror a 0 0 0 1 0 0
+
+checkshape a
+
+display a
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}-mirror-2d.png
+
+vclear
+vdisplay a
+vfit
+checkview -screenshot -3d -path ${imagedir}/${test_image}-mirror-3d.png
--- /dev/null
+puts "TODO OCC28656 ALL: TopoDS_LockedShape: BRep_Builder::UpdateEdge"
+
+puts "========"
+puts "OCC28656"
+puts "========"
+puts ""
+#####################################
+## 3d offset modifies the input shape
+#####################################
+
+pcylinder s 5 15
+
+setflags s locked
+
+explode s f
+
+offsetparameter 1e-7 c i
+offsetload s 1 s_2
+
+catch {offsetperform result}
+
+checkview -display result -2d -path ${imagedir}/${test_image}-2d.png
--- /dev/null
+puts "TODO OCC28696 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28696"
+puts "========"
+puts ""
+############################################
+# Offset 2D algorithm produces micro edges
+############################################
+
+restore [locate_data_file OCC16667-wire.brep] a
+
+mkoffset resoffset a 1 20
+renamevar resoffset_1 result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: Micro edge is produced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28696 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28696"
+puts "========"
+puts ""
+############################################
+# Offset 2D algorithm produces micro edges
+############################################
+
+restore [locate_data_file OCC16667-wire.brep] a
+
+mkoffset resoffset a 1 -20
+renamevar resoffset_1 result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ regexp {Mass : *([0-9\-+.eE]+)} [lprops $e] dummy len
+ regexp {Tolerance MAX=([0-9\-+.eE]+)} [tolerance $e] dummy tol
+ puts "ERROR: Micro edge is produced. Edge $e (length=$len, tolerance=$tol) is too small"
+ }
+}
--- /dev/null
+puts "TODO OCC28700 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28700"
+puts "========"
+puts ""
+#########################################################################
+# BRepBuilderAPI_Sewing produces too small edge covered by its vertices
+#########################################################################
+
+restore [locate_data_file OCC714.brep] a
+
+sewing result 0.1 a
+checkshape result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ puts "ERROR: Micro edge is produced. Edge $e is too small."
+ }
+}
--- /dev/null
+puts "TODO OCC28700 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28700"
+puts "========"
+puts ""
+#########################################################################
+# BRepBuilderAPI_Sewing produces too small edge covered by its vertices
+#########################################################################
+
+restore [locate_data_file OCC22804-sew_bug.brep] a
+
+sewing result 200 a
+checkshape result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ puts "ERROR: Micro edge is produced. Edge $e is too small."
+ }
+}
--- /dev/null
+puts "TODO OCC28700 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28700"
+puts "========"
+puts ""
+#########################################################################
+# BRepBuilderAPI_Sewing produces too small edge covered by its vertices
+#########################################################################
+
+restore [locate_data_file 22770-tramp.brep] a
+restore [locate_data_file 22770-trans.brep] b
+
+sewing result 0.1 a b
+checkshape result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ puts "ERROR: Micro edge is produced. Edge $e is too small."
+ }
+}
--- /dev/null
+puts "TODO OCC28700 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28700"
+puts "========"
+puts ""
+#########################################################################
+# BRepBuilderAPI_Sewing produces too small edge covered by its vertices
+#########################################################################
+
+restore [locate_data_file 22770-tramp.brep] a
+restore [locate_data_file 22770-trans.brep] b
+
+sewing result 0.1 a b -c
+checkshape result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ puts "ERROR: Micro edge is produced. Edge $e is too small."
+ }
+}
--- /dev/null
+puts "TODO OCC28700 ALL: ERROR: Micro edge is produced."
+
+puts "========"
+puts "OCC28700"
+puts "========"
+puts ""
+#########################################################################
+# BRepBuilderAPI_Sewing produces too small edge covered by its vertices
+#########################################################################
+
+restore [locate_data_file 22770-tramp.brep] a
+restore [locate_data_file 22770-trans.brep] b
+
+sewing result 0.1 a b -p
+checkshape result
+
+foreach e [explode result e] {
+ if {[validrange $e] == "edge has no valid range"} {
+ puts "ERROR: Micro edge is produced. Edge $e is too small."
+ }
+}
--- /dev/null
+puts "TODO OCC28722 ALL: Faulty shapes in variables faulty_1 to faulty_"
+
+puts "========"
+puts "OCC28722"
+puts "========"
+puts ""
+########################################################################
+# Conversion of a spherical face to a spline produces an invalid shape
+########################################################################
+
+restore [locate_data_file bug28722_s.brep] s
+
+nurbsconvert r s
+
+checkshape r
--- /dev/null
+puts "TODO OCC28739 ALL: Faulty shapes in variables faulty_1 to faulty_"
+
+puts "========"
+puts "OCC28739"
+puts "========"
+puts ""
+#######################
+# Draft on face fails
+#######################
+
+restore [locate_data_file bug28739_draft.brep] draft
+
+explode draft f
+depouille result draft 0 1 0 draft_7 87 11 -5 0 1 0 0
+
+checkshape result
--- /dev/null
+puts "TODO OCC5081 ALL: Faulty shapes in variables faulty_1 to faulty_"
+puts "TODO OCC5081 ALL: Error: BRepOffset_MakeOffsetShape algorithm does not return valid result"
+
+puts "======="
+puts "OCC5081"
+puts "======="
+puts ""
+####################################################################
+# BRepOffset_MakeOffsetShape algorithm does not return valid result.
+####################################################################
+
+restore [locate_data_file bug5582_shape1.brep] comp
+
+explode comp so
+
+offsetparameter 0.00001 p a
+offsetload comp_1 1
+offsetperform res
+
+checkshape res
+
+set Log [bopcheck res]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BRepOffset_MakeOffsetShape algorithm does not return valid result"
+}
+
+smallview
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "======="
+puts "OCC5081"
+puts "======="
+puts ""
+####################################################################
+# BRepOffset_MakeOffsetShape algorithm does not return valid result.
+####################################################################
+
+restore [locate_data_file bug5081_shape2.brep] comp
+
+explode comp so
+
+offsetparameter 0.00001 p i
+offsetload comp_1 2
+offsetperform res
+
+checkshape res
+
+set Log [bopcheck res]
+if {[regexp "This shape seems to be OK" ${Log}] != 1} {
+ puts "Error: BRepOffset_MakeOffsetShape algorithm does not return valid result"
+}
+
+smallview
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC5582 ALL: Faulty shapes in variables faulty_1 to faulty_"
+
+puts "======="
+puts "OCC5582"
+puts "======="
+puts ""
+################################################################
+# Impossible to make offset on the shape with degenerated edge
+################################################################
+
+restore [locate_data_file bug5582_shape1.brep] comp
+
+checkshape comp
+explode comp so
+offsetparameter 0.00001 p a
+offsetload comp_1 1
+offsetperform result
+
+checkshape result
--- /dev/null
+puts "====="
+puts "OCC83"
+puts "====="
+puts ""
+#####################################################################
+# BUC60912. Section of simple BSpline surfaces is performed too slow.
+#####################################################################
+
+restore [locate_data_file BUC60912_sec_slow.brep] c
+
+explode c
+renamevar c_1 sh
+renamevar c_2 pr
+
+plane f 0 0 0 1 0 0
+mkface f f -11 11 -11 11
+
+puts "Info: perform section with plane"
+chrono h1 reset; chrono h1 start
+section r1 f pr
+chrono h1 stop counter "CPU section r1"
+
+puts "Info: perform section with planar BSpline surface"
+chrono h2 reset; chrono h2 start
+section r2 sh pr
+chrono h2 stop counter "CPU section r2"
+
+regexp {Elapsed time: +([-0-9.+eE]+) Hours +([-0-9.+eE]+) Minutes +([-0-9.+eE]+) Seconds} [dchrono h1 show] full h1_Hours h1_Minutes h1_Seconds
+regexp {Elapsed time: +([-0-9.+eE]+) Hours +([-0-9.+eE]+) Minutes +([-0-9.+eE]+) Seconds} [dchrono h2 show] full h2_Hours h2_Minutes h2_Seconds
+
+set h1_Time [expr ${h1_Hours}*60.*60. + ${h1_Minutes}*60. + ${h1_Seconds} ]
+set h2_Time [expr ${h2_Hours}*60.*60. + ${h2_Minutes}*60. + ${h2_Seconds} ]
+
+if { ${h1_Time} > 0.1 } {
+ puts "Error: Section of simple BSpline surfaces_1 is performed too slow"
+}
+
+if { ${h2_Time} > 0.1 } {
+ puts "Error: Section of simple BSpline surfaces_2 is performed too slow"
+}
-puts "TODO OCC11111 ALL: OCC2442 Faulty"
-
puts "============"
puts "OCC2442"
puts "============"
# Error in BRepClass3d_SolidClassifier
######################################################
-set IsGood 1
-
restore [locate_data_file OCC2442-1.brep] a
restore [locate_data_file OCC2442-2.brep] b
distmini dm1 a b
-set dm1_list [dump dm1_val]
-set dm1_length [llength $dm1_list]
-if {$dm1_length < 6} {
- puts "Faulty OCC2442"
- set IsGood 0
-}
+set dist1 [dval dm1_val]
explode a
explode b
distmini dm2 a_1 b_1
-set dm2_list [dump dm2_val]
-set dm2_length [llength $dm2_list]
-if {$dm2_length < 6} {
- puts "Faulty OCC2442"
- set IsGood 0
-}
-
-if {$IsGood == 1} {
- regexp {([-0-9.+eE]+)} $dm1_list full dist1
- regexp {([-0-9.+eE]+)} $dm2_list full dist2
-
- set good_dist 18.4816355578064
- set dist1_percent [expr abs(${dist1} - ${good_dist}) / double(${good_dist}) * 100.]
-
- set dist2_percent [expr abs(${dist1} - ${dist2}) / double(${dist2}) * 100.]
-
- set percent_max 0.1
-
- if {${dist1_percent} > ${percent_max}} {
- puts "OCC2442 Faulty"
- set IsGood 0
- }
- if {${dist2_percent} > ${percent_max}} {
- puts "OCC2442 Faulty"
- set IsGood 0
- }
- if {${IsGood} == 1} {
- puts "OCC2442 OK"
- }
-}
+set dist2 [dval dm2_val]
+
+set good_dist 18.4816355578064
+
+set tol_abs 1.e-7
+set tol_rel 1.e-7
+
+checkreal "Distance 1 " ${dist1} ${good_dist} ${tol_abs} ${tol_rel}
+checkreal "Distance 2 " ${dist2} ${good_dist} ${tol_abs} ${tol_rel}
set boundbox [boundingstr a]
set x0 [lindex $boundbox 0]
set z0 [lindex $boundbox 2]
ttranslate a [expr -1 * $x0] [expr -1 * $y0] [expr -1 * $z0]
ttranslate b [expr -1 * $x0] [expr -1 * $y0] [expr -1 * $z0]
+
+checkview -display a -with b -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-
-puts "================"
-puts "OCC862"
-puts "================"
-puts ""
-########################################
-## The result is just one extremum - intersection is not found.
-########################################
-restore [locate_data_file OCC862_1.draw] c1
-restore [locate_data_file OCC862_2.draw] c2
-
-set result [extrema c1 c2]
-set err [llength $result]
-if { $err != 1} {
- puts "Faulty OCC862 (amount of solution): command extrema does NOT work properly"
-} else {
- puts "OCC862 OK (amount of solution): command extrema works properly"
-}
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
-
--- /dev/null
+puts "======="
+puts "OCC5145"
+puts "======="
+puts ""
+#####################################################
+# Wrong result of projection of a circle on a sphere.
+#####################################################
+
+restore [locate_data_file bug5145_f1.brep] f1
+restore [locate_data_file bug5145_c.draw] c
+
+mksurface s f1
+
+trim c1 c 0 pi
+trim c2 c pi 2.*pi
+
+project c2d1 c1 s
+project c2d2 c2 s
+
+checklength c2d1 -l 3.68009
+checklength c2d2 -l 3.68009
+
+v2d
+2dfit
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC28662"
+puts "========"
+puts ""
+############################################################
+# Data Exchange - Exception during reading large STEP file
+############################################################
+
+stepread [locate_data_file bug28662_3741842_A-SEAT_OCCUPANT_UPGRADE_KIT.step] a *