1. Modification in method BRepFill_Filling::Build - correction of building the wire.
2. Create new subgroup "filling" in the group "bugs".
gp_Pnt aPnt = BRep_Tool::Pnt(V1);
NewV1 = BRepLib_MakeVertex(aPnt);
BB.UpdateVertex(NewV1, dmax);
+ myOldNewMap.Bind(V1.Oriented(TopAbs_FORWARD), NewV1);
}
if (myOldNewMap.IsBound(V2))
gp_Pnt aPnt = BRep_Tool::Pnt(V2);
NewV2 = BRepLib_MakeVertex(aPnt);
BB.UpdateVertex(NewV2, dmax);
+ myOldNewMap.Bind(V2.Oriented(TopAbs_FORWARD), NewV2);
}
NewV1.Orientation(TopAbs_FORWARD);
BRepLib::SameParameter(NewEdge, dmax, Standard_True);
FinalEdges.Append(NewEdge);
myOldNewMap.Bind(InitEdge.Oriented(TopAbs_FORWARD), NewEdge.Oriented(TopAbs_FORWARD));
- myOldNewMap.Bind(V1.Oriented(TopAbs_FORWARD), NewV1.Oriented(TopAbs_FORWARD));
- if (!V1.IsSame(V2))
- myOldNewMap.Bind(V2.Oriented(TopAbs_FORWARD), NewV2.Oriented(TopAbs_FORWARD));
}
TopoDS_Wire FinalWire = WireFromList(FinalEdges);
--- /dev/null
+set subgroup filling
+
+
+
--- /dev/null
+puts "==========="
+puts "OCC13904"
+puts "==========="
+######################################################
+# Exception during "filling" operation
+######################################################
+
+set BugNumber OCC13904
+
+circle c 0 100 100 0 1 1 50
+ellipse el 0 0 0 0 1 1 100 50
+
+set mistake 0
+if [catch { appsurf result c el } res] {
+ set mistake 1
+ puts "Faulty ${BugNumber}: filling problem"
+} else {
+ puts "Filling ${BugNumber} OK"
+ set What [whatis result]
+ if { [regexp "surface" $What] != 1 } {
+ set mistake 1
+ } else {
+ set mistake 0
+ }
+}
+
+# Resume
+puts ""
+if { ${mistake} != 0 } {
+ puts "Faulty ${BugNumber}"
+} else {
+ puts "OK ${BugNumber}"
+}
--- /dev/null
+puts "============"
+puts "OCC16119"
+puts "============"
+puts ""
+#######################################################################
+# Bug in GeomFill_Coons algorithm
+#######################################################################
+
+set BugNumber OCC16119
+
+restore [locate_data_file OCC16119-c1.draw] c1
+restore [locate_data_file OCC16119-c2.draw] c2
+restore [locate_data_file OCC16119-c31.draw] c31
+restore [locate_data_file OCC16119-c32.draw] c32
+restore [locate_data_file OCC16119-c41.draw] c41
+restore [locate_data_file OCC16119-c42.draw] c42
+restore [locate_data_file OCC16119-cv.draw] cv
+
+fillcurves s11 c1 c41 cv c31
+fillcurves s12 cv c42 c2 c32
+
+svalue s11 .5 .5 x1 y1 z1 dux1 duy1 duz1 dvx1 dvy1 dvz1
+svalue s12 .5 .5 x2 y2 z2 dux2 duy2 duz2 dvx2 dvy2 dvz2
+
+set deltaX [dval dvx1-dvx2]
+set deltaY [dval dvy1-dvy2]
+set deltaZ [dval dvz1-dvz2]
+
+checkreal "deltaX" ${deltaX} -3.5527136788005009e-015 0 0.001
+checkreal "deltaY" ${deltaY} -3.5527136788005009e-015 0 0.001
+checkreal "deltaZ" ${deltaZ} 8.8817841970012523e-016 0 0.001
--- /dev/null
+puts "============"
+puts "OCC16833"
+puts "============"
+puts ""
+#######################################################################
+# Error in Coons algorithm
+#######################################################################
+
+set BugNumber OCC16833
+
+restore [locate_data_file OCC16833-c1.draw] c1
+restore [locate_data_file OCC16833-c2.draw] c2
+restore [locate_data_file OCC16833-c3.draw] c3
+restore [locate_data_file OCC16833-c4.draw] c4
+
+set mistake 0
+if [catch { fillcurves result c1 c2 c3 c4 } res] {
+ set mistake 1
+ puts "Faulty ${BugNumber}: filling problem"
+} else {
+ puts "Filling ${BugNumber} OK"
+ set What [whatis result]
+ if { [regexp "surface" $What] != 1 } {
+ set mistake 1
+ } else {
+ set mistake 0
+ }
+}
+
+# Resume
+puts ""
+if { ${mistake} != 0 } {
+ puts "Faulty ${BugNumber}"
+} else {
+ puts "OK ${BugNumber}"
+}
+
--- /dev/null
+puts "TODO OCC24156 MacOS: \\*\\* Exception \\*\\*.*"
+puts "TODO OCC24156 MacOS: An exception was caught"
+puts "TODO OCC24156 MacOS: TEST INCOMPLETE"
+
+puts "==========="
+puts "OCC22783"
+puts "==========="
+puts ""
+#######################################################################
+# Improvement of BRepOffsetAPI_MakeFilling: keep old and new boundary edges with all pcurves
+#######################################################################
+
+catch {pload XDE}
+
+set BugNumber OCC22783
+
+restore [locate_data_file bug22783_cs.brep] a
+explode a
+explode a_1 e
+explode a_1_6
+explode a_1_13
+edge e1 a_1_6_1 a_1_13_1
+edge e2 a_1_6_2 a_1_13_2
+smallview
+donly a_1_6 a_1_13 e1 e2
+fit
+
+filling result 4 0 0 a_1_6 0 a_1_13 0 e1 0 e2 0
+tolerance result
+checkshape result
+dump result
+
+checkprops result -s 0.00456273
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC24156 MacOS: \\*\\* Exception \\*\\*.*"
+puts "TODO OCC24156 MacOS: An exception was caught"
+puts "TODO OCC24156 MacOS: TEST INCOMPLETE"
+
+puts "============"
+puts "OCC22786"
+puts "============"
+puts ""
+#######################################################################
+# 64bit issue in AdvApp2Var
+#######################################################################
+
+set BugNumber OCC22786
+
+restore [locate_data_file OCC22786-c.brep] c
+
+explode c
+
+gplate result 5 0 c_1 0 c_2 0 c_3 0 c_4 0 c_5 0
+
+checkprops result -s 2.92409
+checkshape result
+
+checknbshapes result -vertex 4 -edge 4 -wire 1 -face 1 -shell 0 -solid 0 -compsolid 0 -compound 0 -shape 10
+
+vinit
+vdisplay c_1 c_2 c_3 c_4 c_5
+vdisplay result
+vsetdispmode 1
+vfit
+
+checkview -screenshot -3d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "TODO OCC23343 ALL: \\*\\* Exception \\*\\*.*"
+puts "TODO OCC23343 ALL: An exception was caught"
+puts "TODO OCC23343 ALL: Faulty OCC23343"
+
+puts "============"
+puts "OCC23343"
+puts "============"
+puts ""
+#######################################################################
+# Crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface / MakeApprox if init Surface is set
+#######################################################################
+
+restore [locate_data_file bug23343_initFace.brep] initFace
+restore [locate_data_file bug23343_edge_constraint.brep] edge_constraint
+
+point p1 30 -33.4729635533385 49.7661550602442
+point p2 30 -49.6961550602442 33.3929635533386
+point p3 23.3333333333333 -50 30.07
+point p4 -30 -33.4729635533386 49.6161550602442
+
+if [catch {gplate result 1 4 initFace edge_constraint 0 p1 p2 p3 p4} catch_result] {
+ puts "Faulty OCC23343: there is crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface"
+} else {
+ puts "OK OCC23343: there is not crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface"
+}
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "======================================================================================="
+puts "OCC23380: BRepOffsetAPI_MakeFilling fails and leaves boundary faces with high tolerance"
+puts "======================================================================================="
+puts ""
+
+brestore [locate_data_file bug23380.brep] b
+
+explode b
+renamevar b_5 d
+renamevar b_1 f
+renamevar b_4 i
+explode f E
+explode d E
+tolerance f
+donly f_1 d_3 b_2 b_3
+
+filling result 4 0 0 i f_1 f 1 d_3 d 1 b_2 0 b_3 0
+
+checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 230.} {
+ puts "Error: bad tolerance of result"
+}
--- /dev/null
+puts "REQUIRED All: Standard_ConstructionError\: GeomFill_BSplineCurves\: invalid filling style"
+
+puts "========"
+puts "OCC27704"
+puts "========"
+puts ""
+#################################################
+# Different behavior of GeomFill_BSplineCurves algorithm in DEBUG and RELEASE mode
+#################################################
+
+#Indeed, the input data are invalid here:
+#1. Algorithm requires B-Spline with 4+ poles. Source curves contains two pole only.
+#2. Four curves must comprise closed region. But it is not here.
+#Therefore, the normal behavior is to throw an exception.
+
+bsplinecurve c1 1 2 0 2 100.000001513789 2 -24033.3957701043 -6337.90755953146 -16577.8188547128 1 -23933.3957701044 -6337.90755953146 -16577.8362547128 1
+bsplinecurve c2 1 2 0 2 100.000001513789 2 -23933.3957701044 -6337.90755953146 -16577.8362547128 1 -24033.3957701043 -6337.90755953146 -16577.8188547128 1
+bsplinecurve c3 1 2 0 2 33.1099999999979 2 -24033.3957701043 -6371.01755953146 -16577.8188547128 1 -24033.3957701043 -6337.90755953146 -16577.8188547128 1
+bsplinecurve c4 1 2 0 2 100.000001513789 2 -24033.3957701043 -6371.01755953146 -16577.8188547128 1 -23933.3957701044 -6371.01755953146 -16577.8362547128 1
+
+if {[catch {fillcurves res c1 c2 c3 c4 2}]} {
+ puts "OK: The incorrect input data were processed correctly!"
+} else {
+ puts "Error: The output result must be invalid because the input data are wrong!"
+}
\ No newline at end of file
--- /dev/null
+puts "REQUIRED All: filling failed"
+
+puts "============"
+puts "OCC27873"
+puts "============"
+puts ""
+######################################################
+# Exception is raised in BRepFill_Filling::FindExtremitiesOfHoles()
+######################################################
+
+# Input data are true invalid.
+# 1. Non-manifold wire;
+# 2. The wire contains internal edge in its boundary (i.e. if we remove this edge we will obtain not-closed wire).
+
+restore [locate_data_file bug27873_filling.brep] a
+explode a
+
+if { ![regexp {filling failed} [filling result 11 0 0 a_1 0 a_2 0 a_3 0 a_4 0 a_5 0 a_6 0 a_7 0 a_8 0 a_9 0 a_10 0 a_11 0] ] } {
+ puts "Error: Null result is expected but is not returned."
+}
--- /dev/null
+puts "============================================================================================="
+puts "OCC31464: BRepOffsetAPI_MakeFilling algorithm increases tolerances of vertices in input edges"
+puts "============================================================================================="
+puts ""
+
+brestore [locate_data_file bug31464.brep] a
+
+set tol [checkmaxtol a]
+
+explode a f
+explode a_1 e
+
+filling result 3 0 1 a_1_1 0 a_1_2 0 a_1_4 0 0.0785398166 0.0196349541 a_1 1
+savehistory hh
+
+set tol2 [checkmaxtol a]
+
+if { ${tol} != ${tol2}} {
+ puts "Error: tolerance of input shape changed"
+}
+
+generated e2 hh a_1_2
+
+explode a_1_3
+generated vv hh a_1_3_1
+
+distmini distvv a_1_3_1 vv
+if {[dval distvv_val] > 0.} {
+ puts "Error: generated vertex is wrong"
+}
+
+mkcurve oldc a_1_2
+mkcurve newc e2
+set log [xdistcc oldc newc -3.92699082e-14 0.0392699082 10]
+
+regexp {Max Distance = +([-0-9.+eE]+)} ${log} full dist
+
+if { [dval dist] != 0. } {
+ puts "Error: generated edge is wrong"
+}
+
+smallview
+donly result e2 vv
+fit
+
+checkshape result
+
+checknbshapes result -face 1 -wire 1 -edge 3 -vertex 3
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 0.0007} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -s 0.00190371
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "=========================================================================="
+puts "OCC31558: BRepOffsetAPI_MakeFilling algorithm makes turned inside out face"
+puts "=========================================================================="
+puts ""
+
+brestore [locate_data_file bug31558.brep] a
+
+explode a e
+
+filling result 1 0 9 a_2 0 3.5000410449283663 0.62831853071795896 a 1 3.5000410449283663 1.2566370614359179 a 1 3.5000410449283663 1.8849555921538768 a 1 3.5000410449283663 2.5132741228718358 a 1 3.5000410449283663 3.1415926535897949 a 1 3.5000410449283663 3.7699111843077535 a 1 3.5000410449283663 4.3982297150257130 a 1 3.5000410449283663 5.0265482457436717 a 1 3.5000410449283663 5.6548667764616303 a 1
+
+checkshape result
+
+checknbshapes result -face 1 -wire 1 -edge 1 -vertex 1
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 2.e-5} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -s 153.938
+
+smallview
+isos result 10
+donly result
+fit
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
020 stlvrml
021 splitshape
022 splitshape_1
+023 filling
\ No newline at end of file
--- /dev/null
+puts "========"
+puts "OCC26466"
+puts "========"
+puts ""
+#######################################################################
+# UnifySameDomain creates invalid result shape from valid input shape
+#######################################################################
+
+restore [locate_data_file OCC26466-invalid_unifysamedom_input.brep] s
+checkshape s
+unifysamedom r s
+checkshape r
--- /dev/null
+puts "========"
+puts "OCC27004"
+puts "========"
+puts ""
+#####################################################
+# ShapeUpgrade_UnifySameDomain produces invalid result
+#####################################################
+
+restore [locate_data_file bug27004_prim_0_1.brep] s0
+restore [locate_data_file bug27004_prim_0_29.brep] s1
+restore [locate_data_file bug27004_prim_0_30.brep] s2
+
+bclear
+bfuzzyvalue 1e-5
+
+baddobjects s0 s1 s2
+baddtools s0 s1 s2
+
+bfillds
+
+bbop r 1
+
+unifysamedom result r
+
+checkshape result
+
+checknbshapes result -vertex 12 -edge 18 -wire 8 -face 8 -solid 1
+checkprops result -s 223704 -v 3.27888e+006
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes1.brep] a
+explode a
+bcut r1 a_1 a_3
+bfuse r2 r1 a_2
+unifysamedom result r2
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 22 -edge 40
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes1.brep] a
+explode a
+bcut r1 a_1 a_3
+bfuse r2 r1 a_2
+unifysamedom result r2 +i
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 14 -edge 28
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes2.brep] a
+explode a
+bfuse r a_1 a_2
+unifysamedom result r
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 37 -edge 94
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes2.brep] a
+explode a
+bfuse r a_1 a_2
+unifysamedom result r +i
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 33 -edge 86
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes3.brep] a
+unifysamedom result a
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 249 -edge 600
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27082"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
+###############################
+
+restore [locate_data_file bug27082_shapes3.brep] a
+unifysamedom result a +i
+
+don result
+smallview; l; fit
+bopcheck result
+checknbshapes result -m UnifySameDomain -face 225 -edge 576
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC27199"
+puts "========"
+puts ""
+##############################################
+# Unifysamedomain regression issue in OCCT 7
+##############################################
+
+restore [locate_data_file bug27199_i1_i2.brep] sh
+
+explode sh
+bop sh_1 sh_2
+bopfuse r
+unifysamedom result r
+checkshape result
+
+checknbshapes result -face 1
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27271"
+puts "============"
+puts ""
+###########################################################################################################
+# Unifysamedomain invalid result
+###########################################################################################################
+
+restore [locate_data_file bug27271_Shape.brep] a
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -vertex 44 -edge 81 -wire 45 -face 35 -shell 3 -solid 3
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 0.003} {
+ puts "Error: bad tolerance of result"
+}
+
+explode result
+checkprops result_1 -v 1109.52
+checkprops result_2 -v 7.50891
+checkprops result_3 -v 7.51022
--- /dev/null
+puts "============"
+puts "OCC27309"
+puts "============"
+puts ""
+###############################
+## Result of UnifySameDomain has InvalidMultiConnexity error
+###############################
+
+restore [locate_data_file bug27309_shape.brep] a
+unifysamedom result a
+
+don result
+smallview; l; fit
+checkshape result
+checknbshapes result -m UnifySameDomain -face 28 -edge 66
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27315"
+puts "============"
+puts ""
+###############################
+## UnifySameDomain leaves unmerged edges
+###############################
+
+restore [locate_data_file bug27315_fused.brep] a
+unifysamedom result a
+
+checkshape result
+checknbshapes result -m "unifysamedom" -edge 141
+
+subshape a e 85
+don a_85
+smallview; fit
+repeat 20 md; repeat 3 pr
+don result
+explode result v
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27521"
+puts "============"
+puts ""
+###############################
+## Standard_ConstructionError when trying to use unifySameDom into a shape
+###############################
+
+restore [locate_data_file bug27521_dom8443-good.brep] a
+unifysamedom result a
+
+don result
+smallview; fit
+checkshape result
+checknbshapes result -m UnifySameDomain -face 31 -edge 286
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============"
+puts "OCC27521"
+puts "============"
+puts ""
+###############################
+## Standard_ConstructionError when trying to use unifySameDom into a shape
+###############################
+
+restore [locate_data_file bug27521_dom8443-wrong.brep] a
+unifysamedom result a
+
+don result
+smallview; fit
+checkshape result
+checknbshapes result -m UnifySameDomain -face 31 -edge 286
+
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC28207"
+puts "========"
+puts ""
+#########################################################
+## Unexpected result of the unify same domain algorithm
+#########################################################
+
+restore [locate_data_file bug28207_face.brep] s1
+
+unifysamedom result1 s1
+checkshape result1
+checknbshapes result1 -face 1 -wire 1 -edge 984
+checkprops result1 -l 10402.1
+
+#safeInputMode is true for USD
+unifysamedom result2 s1 -a 0.06
+checkshape result2
+checknbshapes result2 -face 1 -wire 1 -edge 983
+checkprops result2 -l 10402.1
+
+unifysamedom result3 s1 -a 57
+checkshape result3
+checknbshapes result3 -face 1 -wire 1 -edge 983
+checkprops result3 -l 10402.1
+
+unifysamedom result4 s1 -t 0.01 -a 5.7
+checkshape result4
+checknbshapes result4 -face 1 -wire 1 -edge 510
+checkprops result4 -l 10402.1
+
+unifysamedom result5 s1 -t 0.1 -a 5.7
+checkshape result5
+checknbshapes result5 -face 1 -wire 1 -edge 198
+checkprops result5 -l 10402.1
+
+unifysamedom result6 s1 -t 1.0 -a 5.7
+checkshape result6
+checknbshapes result6 -face 1 -wire 1 -edge 65
+checkprops result6 -l 10401.9
+
+checkview -display result1 -2d -path ${imagedir}/${test_image}.png
\ No newline at end of file
--- /dev/null
+puts "========"
+puts "OCC28343"
+puts "========"
+puts ""
+#################################################
+# Modeling: ShapeUpgrade_UnifySameDomain algorithm produces invalid shape
+#################################################
+
+restore [locate_data_file bug28343_shape1.brep] s
+
+unifysamedom result s -a 0.005
+checkshape result
+bopargcheck result
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "========"
+puts "OCC28343"
+puts "========"
+puts ""
+#################################################
+# Modeling: ShapeUpgrade_UnifySameDomain algorithm produces invalid shape
+#################################################
+
+restore [locate_data_file bug28343_shape2.brep] s
+
+unifysamedom result s -a 0.005
+checkshape result
+bopargcheck result
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "======="
+puts "0028995"
+puts "======="
+puts ""
+##################################################
+# UnifySameDomain produces invalid shape
+##################################################
+
+brestore [locate_data_file bug28995_s1.brep] s1
+brestore [locate_data_file bug28995_s2.brep] s2
+
+# perform fuse operation
+bfuse rfuse s1 s2
+
+# check the result of fuse
+checkshape rfuse
+
+if {![regexp "This shape seems to be OK" [bopcheck rfuse]]} {
+ puts "Error: The result of FUSE operation is a self-intersecting shape."
+}
+
+# unify faces and edges in the fused shape
+unifysamedom result rfuse
+
+# check unified result
+checkshape result
+
+if {![regexp "This shape seems to be OK" [bopcheck result]]} {
+ puts "Error: The result of UnifySameDomain algorithm is a self-intersecting shape."
+}
+
+checknbshapes result -vertex 200 -edge 300 -wire 104 -face 103 -solid 1
+checkprops result -s 1.59154e+006 -v 1.1497e+007
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
\ No newline at end of file
--- /dev/null
+puts "================================================================================"
+puts "OCC29382: ShapeUpgrade_UnifySameDomain algorithm incorrectly processes the shape"
+puts "================================================================================"
+puts ""
+
+restore [locate_data_file bug29382_Group_3.brep] a
+
+unifysamedom result a
+
+checkshape result
+checkshape a
+
+checknbshapes result -solid 3 -shell 3 -face 18 -wire 18 -edge 36 -vertex 22
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.8066863810061599e-05} {
+ puts "Error: bad tolerance of result"
+}
+
+explode result
+checkprops result_1 -v 4.41996e-06
+checkprops result_2 -v 1.30453e-06
+checkprops result_3 -v 1.16532e-06
--- /dev/null
+puts "========"
+puts "OCC29502"
+puts "========"
+puts ""
+#################################################
+# Improve performance of the ShapeUpgrade_UnifySameDomain::UnifyEdges() method
+#################################################
+
+# create cylinder
+cylinder c 0 0 0 0 0 1 10
+mkface f c 0 2*pi -10 10
+
+# split seam edge by the vertex
+vertex v 10 0 0
+bclearobjects
+bcleartools
+baddobjects f
+baddtools v
+bfillds
+bsplit r
+
+checknbshapes r -vertex 3 -edge 4 -wire 1 -face 1
+
+# perform unification of the seam edge:
+# the split vertex should be removed
+unifysamedom result r
+
+checkshape result
+checkprops result -equal f
+checknbshapes result -ref [nbshapes f]
+
--- /dev/null
+puts "===================================================================================================="
+puts "OCC29504: ShapeUpgrade_UnifySameDomain produces invalid shape and ShapeFix_Shape is unable to fix it"
+puts "===================================================================================================="
+puts ""
+
+restore [locate_data_file bug29504_cyl.brep] s
+unifysamedom result s
+
+checkshape result
+checkshape s
+
+checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.000008e-07} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -s 104.72
--- /dev/null
+puts "===================================================================================================="
+puts "OCC29504: ShapeUpgrade_UnifySameDomain produces invalid shape and ShapeFix_Shape is unable to fix it"
+puts "===================================================================================================="
+puts ""
+
+restore [locate_data_file bug29504_sph.brep] s
+unifysamedom result s
+
+checkshape result
+checkshape s
+
+checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.000008e-07} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -s 55.1286
--- /dev/null
+puts "========"
+puts "OCC29544"
+puts "========"
+puts ""
+#################################################
+# Regression vs 7.2.0: ShapeUpgrade_UnifySameDomain fails to merge linear edges
+#################################################
+
+restore [locate_data_file bug29544_edges.brep] ce
+unifysamedom result ce
+
+checkshape result
+checkprops result -equal ce
+checknbshapes result -vertex 4 -edge 2
+
--- /dev/null
+puts "========"
+puts "OCC29544"
+puts "========"
+puts ""
+#################################################
+# Regression vs 7.2.0: ShapeUpgrade_UnifySameDomain fails to merge linear edges
+#################################################
+
+# create edge
+line l 0 0 0 1 0 0
+mkedge e l 0 10
+
+# split edge by the vertex
+vertex v 5 2.e-7 0
+bclearobjects
+bcleartools
+baddobjects e
+baddtools v
+bfillds
+bsplit sp
+
+# unify the splits of the edge
+unifysamedom result sp
+
+checkshape result
+checkprops result -l 10
+checknbshapes result -vertex 2 -edge 1
--- /dev/null
+puts "========"
+puts "OCC29845:UnifySameDomain does not account the accumulated angle when unifying edges"
+puts "========"
+puts ""
+
+brestore [locate_data_file bug29845_wire.brep] w
+
+# set the linear deflection very high, so the unification
+# will be controlled by the angular deflection only.
+# with the angular deflection of 5 degrees the resulting
+# wire should preserve all the features of the original wire
+
+unifysamedom result w -t 10000 -a 5
+checkshape result
+checknbshapes result -vertex 77 -edge 77
+checkprops result -l 2805.11
+
+smallview +X+Z
+don result
+fit
+checkview -screenshot -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "===================================================================================="
+puts "OCC30099: Modeling Algorithms - ShapeUpgrade_UnifySameDomain produces invalid result"
+puts "===================================================================================="
+puts ""
+
+restore [locate_data_file bug30099.brep] a
+
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 12 -wire 14 -edge 36 -vertex 26
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.2e-05} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 2.04221e+06
--- /dev/null
+puts "========"
+puts "0030100: Modeling Algorithms - ShapeUpgrade_UnifySameDomain is unable to unify faces based on the same toroidal surface"
+puts "========"
+puts ""
+
+restore [locate_data_file bug30100_usd.brep] s
+unifysamedom result s
+checkshape result
+checknbshapes result -wire 1 -face 1
+checkprops result -s 142506
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "==================================================================================="
+puts "OCC30158: Shape Healing - Incorrect result produced by ShapeUpgrade_UnifySameDomain"
+puts "==================================================================================="
+puts ""
+
+restore [locate_data_file bug30158_1.brep] s
+unifysamedom result s
+
+checkshape result
+checkshape s
+
+checknbshapes result -solid 1 -shell 1 -face 6 -wire 6 -edge 12 -vertex 8
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.51e-07} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 48.3068
--- /dev/null
+puts "==================================================================================="
+puts "OCC30158: Shape Healing - Incorrect result produced by ShapeUpgrade_UnifySameDomain"
+puts "==================================================================================="
+puts ""
+
+restore [locate_data_file bug30158_2.brep] s
+unifysamedom result s
+
+checkshape result
+checkshape s
+
+checknbshapes result -solid 1 -shell 1 -face 6 -wire 6 -edge 12 -vertex 8
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.51e-07} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 48.3068
--- /dev/null
+puts "============"
+puts "OCC30174"
+puts "============"
+puts ""
+###########################################################################################################
+# ShapeUpgrade_UnifySameDomain does not unify cylindrical faces
+###########################################################################################################
+
+restore [locate_data_file bug30174_cylinder.brep] a
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -vertex 2 -edge 3 -wire 3 -face 3 -shell 1 -solid 1
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 2.e-5} {
+ puts "Error: bad tolerance of result"
+}
--- /dev/null
+puts "========================================================================="
+puts "OCC30534: Regression in the tool UnifySameDomain - the shape looses faces"
+puts "========================================================================="
+puts ""
+
+binrestore [locate_data_file bug30534_Werth_369.bin] a
+
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 423 -wire 431 -edge 1162 -vertex 736
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 0.00969438844497875} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 18814.1
--- /dev/null
+puts "================================================="
+puts "OCC30714: UnifySameDomain corrupts original shape"
+puts "================================================="
+puts ""
+
+restore [locate_data_file bug30714.brep] s
+explode s
+bcut r s_1 s_2
+unifysamedom result r
+
+checkshape result
+checkshape s_1
+
+checknbshapes result -solid 1 -shell 1 -face 10 -wire 12 -edge 24 -vertex 16
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 1.000008e-07} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 1.20292
--- /dev/null
+puts "======================================================="
+puts "0030897: Modeling Algorithms - Crash in UnifySameDomain"
+puts "======================================================="
+puts ""
+
+restore [locate_data_file bug30897_bleriot_16.brep] a
+
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 51 -wire 121 -edge 379 -vertex 324
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 0.00385} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 403016
--- /dev/null
+puts "======================================================="
+puts "0030905: Modeling Algorithms - Invalid shapes in UnifySameDomain"
+puts "======================================================="
+puts ""
+
+restore [locate_data_file bug30905.brep] a
+
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 56 -wire 61 -edge 148 -vertex 93 -t
+
+checkprops result -s 835.815 -v 339.409
+
+checkview -display result -2d -path ${imagedir}/${test_image}.png
--- /dev/null
+puts "============================================================================"
+puts "0030927: Modeling Algorithms - UnifySameDom looses the Closed flag for wires"
+puts "============================================================================"
+puts ""
+
+box b1 10 10 10
+box b2 5 0 -5 10 10 20
+bfuse s b1 b2
+unifysamedom result s
+
+foreach w [explode result w] {
+ if {![regexp "Closed" [whatis $w]]} {
+ puts "Error: Wire $w is not closed"
+ }
+}
--- /dev/null
+puts "======================================================="
+puts "OCC31066: Infinite loop in ShapeUpgrade_UnifySameDomain"
+puts "======================================================="
+puts ""
+
+pload MODELING DATAEXCHANGE
+
+stepread [locate_data_file bug31066.stp] a *
+
+unifysamedom result a_1
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 140 -wire 174 -edge 352 -vertex 208
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 0.001} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 139105
--- /dev/null
+puts "============================================================="
+puts "OCC31187: Unify same domain algorithm produces invalid shape."
+puts "============================================================="
+puts ""
+
+restore [locate_data_file bug31187_fuse.brep] a
+
+unifysamedom result a -t 1.e-4 -a 1.e-6
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 1 -face 13 -wire 13 -edge 36 -vertex 25
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 6.e-5} {
+ puts "Error: bad tolerance of result"
+}
--- /dev/null
+puts "============================================"
+puts "OCC31441: UnifySameDomain corrupts the shape"
+puts "============================================"
+puts ""
+
+brestore [locate_data_file bug31441.brep] a
+
+unifysamedom result a
+
+checkshape result
+
+checknbshapes result -solid 1 -shell 2 -face 46 -wire 48 -edge 128 -vertex 84
+
+set tolres [checkmaxtol result]
+
+if { ${tolres} > 2.e-7} {
+ puts "Error: bad tolerance of result"
+}
+
+checkprops result -v 1.10788
+++ /dev/null
-puts "TODO OCC24156 MacOS: \\*\\* Exception \\*\\*.*"
-puts "TODO OCC24156 MacOS: An exception was caught"
-puts "TODO OCC24156 MacOS: TEST INCOMPLETE"
-
-puts "==========="
-puts "OCC22783"
-puts "==========="
-puts ""
-#######################################################################
-# Improvement of BRepOffsetAPI_MakeFilling: keep old and new boundary edges with all pcurves
-#######################################################################
-
-catch {pload XDE}
-
-set BugNumber OCC22783
-
-restore [locate_data_file bug22783_cs.brep] a
-explode a
-explode a_1 e
-explode a_1_6
-explode a_1_13
-edge e1 a_1_6_1 a_1_13_1
-edge e2 a_1_6_2 a_1_13_2
-smallview
-donly a_1_6 a_1_13 e1 e2
-fit
-
-filling result 4 0 0 a_1_6 0 a_1_13 0 e1 0 e2 0
-tolerance result
-checkshape result
-dump result
-
-checkprops result -s 0.00456273
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "TODO OCC24156 MacOS: \\*\\* Exception \\*\\*.*"
-puts "TODO OCC24156 MacOS: An exception was caught"
-puts "TODO OCC24156 MacOS: TEST INCOMPLETE"
-
-puts "============"
-puts "OCC22786"
-puts "============"
-puts ""
-#######################################################################
-# 64bit issue in AdvApp2Var
-#######################################################################
-
-set BugNumber OCC22786
-
-restore [locate_data_file OCC22786-c.brep] c
-
-explode c
-
-gplate result 5 0 c_1 0 c_2 0 c_3 0 c_4 0 c_5 0
-
-checkprops result -s 2.92409
-checkshape result
-
-checknbshapes result -vertex 4 -edge 4 -wire 1 -face 1 -shell 0 -solid 0 -compsolid 0 -compound 0 -shape 10
-
-vinit
-vdisplay c_1 c_2 c_3 c_4 c_5
-vdisplay result
-vsetdispmode 1
-vfit
-
-checkview -screenshot -3d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "========"
-puts "OCC26466"
-puts "========"
-puts ""
-#######################################################################
-# UnifySameDomain creates invalid result shape from valid input shape
-#######################################################################
-
-restore [locate_data_file OCC26466-invalid_unifysamedom_input.brep] s
-checkshape s
-unifysamedom r s
-checkshape r
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes1.brep] a
-explode a
-bcut r1 a_1 a_3
-bfuse r2 r1 a_2
-unifysamedom result r2
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 22 -edge 40
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes1.brep] a
-explode a
-bcut r1 a_1 a_3
-bfuse r2 r1 a_2
-unifysamedom result r2 +i
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 14 -edge 28
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes2.brep] a
-explode a
-bfuse r a_1 a_2
-unifysamedom result r
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 37 -edge 94
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes2.brep] a
-explode a
-bfuse r a_1 a_2
-unifysamedom result r +i
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 33 -edge 86
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes3.brep] a
-unifysamedom result a
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 249 -edge 600
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27082"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain must add internal edges where appropriate to resolve self-intersections
-###############################
-
-restore [locate_data_file bug27082_shapes3.brep] a
-unifysamedom result a +i
-
-don result
-smallview; l; fit
-bopcheck result
-checknbshapes result -m UnifySameDomain -face 225 -edge 576
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "========"
-puts "OCC27199"
-puts "========"
-puts ""
-##############################################
-# Unifysamedomain regression issue in OCCT 7
-##############################################
-
-restore [locate_data_file bug27199_i1_i2.brep] sh
-
-explode sh
-bop sh_1 sh_2
-bopfuse r
-unifysamedom result r
-checkshape result
-
-checknbshapes result -face 1
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27271"
-puts "============"
-puts ""
-###########################################################################################################
-# Unifysamedomain invalid result
-###########################################################################################################
-
-restore [locate_data_file bug27271_Shape.brep] a
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -vertex 44 -edge 81 -wire 45 -face 35 -shell 3 -solid 3
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 0.003} {
- puts "Error: bad tolerance of result"
-}
-
-explode result
-checkprops result_1 -v 1109.52
-checkprops result_2 -v 7.50891
-checkprops result_3 -v 7.51022
+++ /dev/null
-puts "============"
-puts "OCC27309"
-puts "============"
-puts ""
-###############################
-## Result of UnifySameDomain has InvalidMultiConnexity error
-###############################
-
-restore [locate_data_file bug27309_shape.brep] a
-unifysamedom result a
-
-don result
-smallview; l; fit
-checkshape result
-checknbshapes result -m UnifySameDomain -face 28 -edge 66
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27315"
-puts "============"
-puts ""
-###############################
-## UnifySameDomain leaves unmerged edges
-###############################
-
-restore [locate_data_file bug27315_fused.brep] a
-unifysamedom result a
-
-checkshape result
-checknbshapes result -m "unifysamedom" -edge 141
-
-subshape a e 85
-don a_85
-smallview; fit
-repeat 20 md; repeat 3 pr
-don result
-explode result v
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27521"
-puts "============"
-puts ""
-###############################
-## Standard_ConstructionError when trying to use unifySameDom into a shape
-###############################
-
-restore [locate_data_file bug27521_dom8443-good.brep] a
-unifysamedom result a
-
-don result
-smallview; fit
-checkshape result
-checknbshapes result -m UnifySameDomain -face 31 -edge 286
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============"
-puts "OCC27521"
-puts "============"
-puts ""
-###############################
-## Standard_ConstructionError when trying to use unifySameDom into a shape
-###############################
-
-restore [locate_data_file bug27521_dom8443-wrong.brep] a
-unifysamedom result a
-
-don result
-smallview; fit
-checkshape result
-checknbshapes result -m UnifySameDomain -face 31 -edge 286
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "REQUIRED All: Standard_ConstructionError\: GeomFill_BSplineCurves\: invalid filling style"
-
-puts "========"
-puts "OCC27704"
-puts "========"
-puts ""
-#################################################
-# Different behavior of GeomFill_BSplineCurves algorithm in DEBUG and RELEASE mode
-#################################################
-
-#Indeed, the input data are invalid here:
-#1. Algorithm requires B-Spline with 4+ poles. Source curves contains two pole only.
-#2. Four curves must comprise closed region. But it is not here.
-#Therefore, the normal behavior is to throw an exception.
-
-bsplinecurve c1 1 2 0 2 100.000001513789 2 -24033.3957701043 -6337.90755953146 -16577.8188547128 1 -23933.3957701044 -6337.90755953146 -16577.8362547128 1
-bsplinecurve c2 1 2 0 2 100.000001513789 2 -23933.3957701044 -6337.90755953146 -16577.8362547128 1 -24033.3957701043 -6337.90755953146 -16577.8188547128 1
-bsplinecurve c3 1 2 0 2 33.1099999999979 2 -24033.3957701043 -6371.01755953146 -16577.8188547128 1 -24033.3957701043 -6337.90755953146 -16577.8188547128 1
-bsplinecurve c4 1 2 0 2 100.000001513789 2 -24033.3957701043 -6371.01755953146 -16577.8188547128 1 -23933.3957701044 -6371.01755953146 -16577.8362547128 1
-
-if {[catch {fillcurves res c1 c2 c3 c4 2}]} {
- puts "OK: The incorrect input data were processed correctly!"
-} else {
- puts "Error: The output result must be invalid because the input data are wrong!"
-}
\ No newline at end of file
+++ /dev/null
-puts "REQUIRED All: filling failed"
-
-puts "============"
-puts "OCC27873"
-puts "============"
-puts ""
-######################################################
-# Exception is raised in BRepFill_Filling::FindExtremitiesOfHoles()
-######################################################
-
-# Input data are true invalid.
-# 1. Non-manifold wire;
-# 2. The wire contains internal edge in its boundary (i.e. if we remove this edge we will obtain not-closed wire).
-
-restore [locate_data_file bug27873_filling.brep] a
-explode a
-
-if { ![regexp {filling failed} [filling result 11 0 0 a_1 0 a_2 0 a_3 0 a_4 0 a_5 0 a_6 0 a_7 0 a_8 0 a_9 0 a_10 0 a_11 0] ] } {
- puts "Error: Null result is expected but is not returned."
-}
+++ /dev/null
-puts "========"
-puts "OCC28207"
-puts "========"
-puts ""
-#########################################################
-## Unexpected result of the unify same domain algorithm
-#########################################################
-
-restore [locate_data_file bug28207_face.brep] s1
-
-unifysamedom result1 s1
-checkshape result1
-checknbshapes result1 -face 1 -wire 1 -edge 984
-checkprops result1 -l 10402.1
-
-#safeInputMode is true for USD
-unifysamedom result2 s1 -a 0.06
-checkshape result2
-checknbshapes result2 -face 1 -wire 1 -edge 983
-checkprops result2 -l 10402.1
-
-unifysamedom result3 s1 -a 57
-checkshape result3
-checknbshapes result3 -face 1 -wire 1 -edge 983
-checkprops result3 -l 10402.1
-
-unifysamedom result4 s1 -t 0.01 -a 5.7
-checkshape result4
-checknbshapes result4 -face 1 -wire 1 -edge 510
-checkprops result4 -l 10402.1
-
-unifysamedom result5 s1 -t 0.1 -a 5.7
-checkshape result5
-checknbshapes result5 -face 1 -wire 1 -edge 198
-checkprops result5 -l 10402.1
-
-unifysamedom result6 s1 -t 1.0 -a 5.7
-checkshape result6
-checknbshapes result6 -face 1 -wire 1 -edge 65
-checkprops result6 -l 10401.9
-
-checkview -display result1 -2d -path ${imagedir}/${test_image}.png
\ No newline at end of file
+++ /dev/null
-puts "========"
-puts "OCC28343"
-puts "========"
-puts ""
-#################################################
-# Modeling: ShapeUpgrade_UnifySameDomain algorithm produces invalid shape
-#################################################
-
-restore [locate_data_file bug28343_shape1.brep] s
-
-unifysamedom result s -a 0.005
-checkshape result
-bopargcheck result
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "========"
-puts "OCC28343"
-puts "========"
-puts ""
-#################################################
-# Modeling: ShapeUpgrade_UnifySameDomain algorithm produces invalid shape
-#################################################
-
-restore [locate_data_file bug28343_shape2.brep] s
-
-unifysamedom result s -a 0.005
-checkshape result
-bopargcheck result
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "TODO OCC23343 ALL: \\*\\* Exception \\*\\*.*"
-puts "TODO OCC23343 ALL: An exception was caught"
-puts "TODO OCC23343 ALL: Faulty OCC23343"
-
-puts "============"
-puts "OCC23343"
-puts "============"
-puts ""
-#######################################################################
-# Crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface / MakeApprox if init Surface is set
-#######################################################################
-
-restore [locate_data_file bug23343_initFace.brep] initFace
-restore [locate_data_file bug23343_edge_constraint.brep] edge_constraint
-
-point p1 30 -33.4729635533385 49.7661550602442
-point p2 30 -49.6961550602442 33.3929635533386
-point p3 23.3333333333333 -50 30.07
-point p4 -30 -33.4729635533386 49.6161550602442
-
-if [catch {gplate result 1 4 initFace edge_constraint 0 p1 p2 p3 p4} catch_result] {
- puts "Faulty OCC23343: there is crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface"
-} else {
- puts "OK OCC23343: there is not crash (ACCESS VIOLATION) in GeomPlate_BuildPlateSurface"
-}
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "======================================================================================="
-puts "OCC23380: BRepOffsetAPI_MakeFilling fails and leaves boundary faces with high tolerance"
-puts "======================================================================================="
-puts ""
-
-brestore [locate_data_file bug23380.brep] b
-
-explode b
-renamevar b_5 d
-renamevar b_1 f
-renamevar b_4 i
-explode f E
-explode d E
-tolerance f
-donly f_1 d_3 b_2 b_3
-
-filling result 4 0 0 i f_1 f 1 d_3 d 1 b_2 0 b_3 0
-
-checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 230.} {
- puts "Error: bad tolerance of result"
-}
+++ /dev/null
-puts "========"
-puts "OCC27004"
-puts "========"
-puts ""
-#####################################################
-# ShapeUpgrade_UnifySameDomain produces invalid result
-#####################################################
-
-restore [locate_data_file bug27004_prim_0_1.brep] s0
-restore [locate_data_file bug27004_prim_0_29.brep] s1
-restore [locate_data_file bug27004_prim_0_30.brep] s2
-
-bclear
-bfuzzyvalue 1e-5
-
-baddobjects s0 s1 s2
-baddtools s0 s1 s2
-
-bfillds
-
-bbop r 1
-
-unifysamedom result r
-
-checkshape result
-
-checknbshapes result -vertex 12 -edge 18 -wire 8 -face 8 -solid 1
-checkprops result -s 223704 -v 3.27888e+006
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "======="
-puts "0028995"
-puts "======="
-puts ""
-##################################################
-# UnifySameDomain produces invalid shape
-##################################################
-
-brestore [locate_data_file bug28995_s1.brep] s1
-brestore [locate_data_file bug28995_s2.brep] s2
-
-# perform fuse operation
-bfuse rfuse s1 s2
-
-# check the result of fuse
-checkshape rfuse
-
-if {![regexp "This shape seems to be OK" [bopcheck rfuse]]} {
- puts "Error: The result of FUSE operation is a self-intersecting shape."
-}
-
-# unify faces and edges in the fused shape
-unifysamedom result rfuse
-
-# check unified result
-checkshape result
-
-if {![regexp "This shape seems to be OK" [bopcheck result]]} {
- puts "Error: The result of UnifySameDomain algorithm is a self-intersecting shape."
-}
-
-checknbshapes result -vertex 200 -edge 300 -wire 104 -face 103 -solid 1
-checkprops result -s 1.59154e+006 -v 1.1497e+007
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
\ No newline at end of file
+++ /dev/null
-puts "================================================================================"
-puts "OCC29382: ShapeUpgrade_UnifySameDomain algorithm incorrectly processes the shape"
-puts "================================================================================"
-puts ""
-
-restore [locate_data_file bug29382_Group_3.brep] a
-
-unifysamedom result a
-
-checkshape result
-checkshape a
-
-checknbshapes result -solid 3 -shell 3 -face 18 -wire 18 -edge 36 -vertex 22
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.8066863810061599e-05} {
- puts "Error: bad tolerance of result"
-}
-
-explode result
-checkprops result_1 -v 4.41996e-06
-checkprops result_2 -v 1.30453e-06
-checkprops result_3 -v 1.16532e-06
+++ /dev/null
-puts "========"
-puts "OCC29502"
-puts "========"
-puts ""
-#################################################
-# Improve performance of the ShapeUpgrade_UnifySameDomain::UnifyEdges() method
-#################################################
-
-# create cylinder
-cylinder c 0 0 0 0 0 1 10
-mkface f c 0 2*pi -10 10
-
-# split seam edge by the vertex
-vertex v 10 0 0
-bclearobjects
-bcleartools
-baddobjects f
-baddtools v
-bfillds
-bsplit r
-
-checknbshapes r -vertex 3 -edge 4 -wire 1 -face 1
-
-# perform unification of the seam edge:
-# the split vertex should be removed
-unifysamedom result r
-
-checkshape result
-checkprops result -equal f
-checknbshapes result -ref [nbshapes f]
-
+++ /dev/null
-puts "===================================================================================================="
-puts "OCC29504: ShapeUpgrade_UnifySameDomain produces invalid shape and ShapeFix_Shape is unable to fix it"
-puts "===================================================================================================="
-puts ""
-
-restore [locate_data_file bug29504_cyl.brep] s
-unifysamedom result s
-
-checkshape result
-checkshape s
-
-checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.000008e-07} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -s 104.72
+++ /dev/null
-puts "===================================================================================================="
-puts "OCC29504: ShapeUpgrade_UnifySameDomain produces invalid shape and ShapeFix_Shape is unable to fix it"
-puts "===================================================================================================="
-puts ""
-
-restore [locate_data_file bug29504_sph.brep] s
-unifysamedom result s
-
-checkshape result
-checkshape s
-
-checknbshapes result -face 1 -wire 1 -edge 4 -vertex 4
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.000008e-07} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -s 55.1286
+++ /dev/null
-puts "========"
-puts "OCC29544"
-puts "========"
-puts ""
-#################################################
-# Regression vs 7.2.0: ShapeUpgrade_UnifySameDomain fails to merge linear edges
-#################################################
-
-restore [locate_data_file bug29544_edges.brep] ce
-unifysamedom result ce
-
-checkshape result
-checkprops result -equal ce
-checknbshapes result -vertex 4 -edge 2
-
+++ /dev/null
-puts "========"
-puts "OCC29544"
-puts "========"
-puts ""
-#################################################
-# Regression vs 7.2.0: ShapeUpgrade_UnifySameDomain fails to merge linear edges
-#################################################
-
-# create edge
-line l 0 0 0 1 0 0
-mkedge e l 0 10
-
-# split edge by the vertex
-vertex v 5 2.e-7 0
-bclearobjects
-bcleartools
-baddobjects e
-baddtools v
-bfillds
-bsplit sp
-
-# unify the splits of the edge
-unifysamedom result sp
-
-checkshape result
-checkprops result -l 10
-checknbshapes result -vertex 2 -edge 1
+++ /dev/null
-puts "========"
-puts "OCC29845:UnifySameDomain does not account the accumulated angle when unifying edges"
-puts "========"
-puts ""
-
-brestore [locate_data_file bug29845_wire.brep] w
-
-# set the linear deflection very high, so the unification
-# will be controlled by the angular deflection only.
-# with the angular deflection of 5 degrees the resulting
-# wire should preserve all the features of the original wire
-
-unifysamedom result w -t 10000 -a 5
-checkshape result
-checknbshapes result -vertex 77 -edge 77
-checkprops result -l 2805.11
-
-smallview +X+Z
-don result
-fit
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "===================================================================================="
-puts "OCC30099: Modeling Algorithms - ShapeUpgrade_UnifySameDomain produces invalid result"
-puts "===================================================================================="
-puts ""
-
-restore [locate_data_file bug30099.brep] a
-
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 12 -wire 14 -edge 36 -vertex 26
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.2e-05} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 2.04221e+06
+++ /dev/null
-puts "========"
-puts "0030100: Modeling Algorithms - ShapeUpgrade_UnifySameDomain is unable to unify faces based on the same toroidal surface"
-puts "========"
-puts ""
-
-restore [locate_data_file bug30100_usd.brep] s
-unifysamedom result s
-checkshape result
-checknbshapes result -wire 1 -face 1
-checkprops result -s 142506
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "==================================================================================="
-puts "OCC30158: Shape Healing - Incorrect result produced by ShapeUpgrade_UnifySameDomain"
-puts "==================================================================================="
-puts ""
-
-restore [locate_data_file bug30158_1.brep] s
-unifysamedom result s
-
-checkshape result
-checkshape s
-
-checknbshapes result -solid 1 -shell 1 -face 6 -wire 6 -edge 12 -vertex 8
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.51e-07} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 48.3068
+++ /dev/null
-puts "==================================================================================="
-puts "OCC30158: Shape Healing - Incorrect result produced by ShapeUpgrade_UnifySameDomain"
-puts "==================================================================================="
-puts ""
-
-restore [locate_data_file bug30158_2.brep] s
-unifysamedom result s
-
-checkshape result
-checkshape s
-
-checknbshapes result -solid 1 -shell 1 -face 6 -wire 6 -edge 12 -vertex 8
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.51e-07} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 48.3068
+++ /dev/null
-puts "============"
-puts "OCC30174"
-puts "============"
-puts ""
-###########################################################################################################
-# ShapeUpgrade_UnifySameDomain does not unify cylindrical faces
-###########################################################################################################
-
-restore [locate_data_file bug30174_cylinder.brep] a
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -vertex 2 -edge 3 -wire 3 -face 3 -shell 1 -solid 1
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 2.e-5} {
- puts "Error: bad tolerance of result"
-}
+++ /dev/null
-puts "========================================================================="
-puts "OCC30534: Regression in the tool UnifySameDomain - the shape looses faces"
-puts "========================================================================="
-puts ""
-
-binrestore [locate_data_file bug30534_Werth_369.bin] a
-
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 423 -wire 431 -edge 1162 -vertex 736
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 0.00969438844497875} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 18814.1
+++ /dev/null
-puts "================================================="
-puts "OCC30714: UnifySameDomain corrupts original shape"
-puts "================================================="
-puts ""
-
-restore [locate_data_file bug30714.brep] s
-explode s
-bcut r s_1 s_2
-unifysamedom result r
-
-checkshape result
-checkshape s_1
-
-checknbshapes result -solid 1 -shell 1 -face 10 -wire 12 -edge 24 -vertex 16
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 1.000008e-07} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 1.20292
+++ /dev/null
-puts "======================================================="
-puts "0030897: Modeling Algorithms - Crash in UnifySameDomain"
-puts "======================================================="
-puts ""
-
-restore [locate_data_file bug30897_bleriot_16.brep] a
-
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 51 -wire 121 -edge 379 -vertex 324
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 0.00385} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 403016
+++ /dev/null
-puts "======================================================="
-puts "0030905: Modeling Algorithms - Invalid shapes in UnifySameDomain"
-puts "======================================================="
-puts ""
-
-restore [locate_data_file bug30905.brep] a
-
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 56 -wire 61 -edge 148 -vertex 93 -t
-
-checkprops result -s 835.815 -v 339.409
-
-checkview -display result -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "============================================================================"
-puts "0030927: Modeling Algorithms - UnifySameDom looses the Closed flag for wires"
-puts "============================================================================"
-puts ""
-
-box b1 10 10 10
-box b2 5 0 -5 10 10 20
-bfuse s b1 b2
-unifysamedom result s
-
-foreach w [explode result w] {
- if {![regexp "Closed" [whatis $w]]} {
- puts "Error: Wire $w is not closed"
- }
-}
+++ /dev/null
-puts "======================================================="
-puts "OCC31066: Infinite loop in ShapeUpgrade_UnifySameDomain"
-puts "======================================================="
-puts ""
-
-pload MODELING DATAEXCHANGE
-
-stepread [locate_data_file bug31066.stp] a *
-
-unifysamedom result a_1
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 140 -wire 174 -edge 352 -vertex 208
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 0.001} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 139105
+++ /dev/null
-puts "============================================================="
-puts "OCC31187: Unify same domain algorithm produces invalid shape."
-puts "============================================================="
-puts ""
-
-restore [locate_data_file bug31187_fuse.brep] a
-
-unifysamedom result a -t 1.e-4 -a 1.e-6
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 1 -face 13 -wire 13 -edge 36 -vertex 25
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 6.e-5} {
- puts "Error: bad tolerance of result"
-}
+++ /dev/null
-puts "============================================"
-puts "OCC31441: UnifySameDomain corrupts the shape"
-puts "============================================"
-puts ""
-
-brestore [locate_data_file bug31441.brep] a
-
-unifysamedom result a
-
-checkshape result
-
-checknbshapes result -solid 1 -shell 2 -face 46 -wire 48 -edge 128 -vertex 84
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 2.e-7} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -v 1.10788
+++ /dev/null
-puts "============================================================================================="
-puts "OCC31464: BRepOffsetAPI_MakeFilling algorithm increases tolerances of vertices in input edges"
-puts "============================================================================================="
-puts ""
-
-brestore [locate_data_file bug31464.brep] a
-
-set tol [checkmaxtol a]
-
-explode a f
-explode a_1 e
-
-filling result 3 0 1 a_1_1 0 a_1_2 0 a_1_4 0 0.0785398166 0.0196349541 a_1 1
-savehistory hh
-
-set tol2 [checkmaxtol a]
-
-if { ${tol} != ${tol2}} {
- puts "Error: tolerance of input shape changed"
-}
-
-generated e2 hh a_1_2
-
-explode a_1_3
-generated vv hh a_1_3_1
-
-distmini distvv a_1_3_1 vv
-if {[dval distvv_val] > 0.} {
- puts "Error: generated vertex is wrong"
-}
-
-mkcurve oldc a_1_2
-mkcurve newc e2
-set log [xdistcc oldc newc -3.92699082e-14 0.0392699082 10]
-
-regexp {Max Distance = +([-0-9.+eE]+)} ${log} full dist
-
-if { [dval dist] != 0. } {
- puts "Error: generated edge is wrong"
-}
-
-smallview
-donly result e2 vv
-fit
-
-checkshape result
-
-checknbshapes result -face 1 -wire 1 -edge 3 -vertex 3
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 0.0007} {
- puts "Error: bad tolerance of result"
-}
-
-checkprops result -s 0.00190371
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png
+++ /dev/null
-puts "==========="
-puts "OCC13904"
-puts "==========="
-######################################################
-# Exception during "filling" operation
-######################################################
-
-set BugNumber OCC13904
-
-circle c 0 100 100 0 1 1 50
-ellipse el 0 0 0 0 1 1 100 50
-
-set mistake 0
-if [catch { appsurf result c el } res] {
- set mistake 1
- puts "Faulty ${BugNumber}: filling problem"
-} else {
- puts "Filling ${BugNumber} OK"
- set What [whatis result]
- if { [regexp "surface" $What] != 1 } {
- set mistake 1
- } else {
- set mistake 0
- }
-}
-
-# Resume
-puts ""
-if { ${mistake} != 0 } {
- puts "Faulty ${BugNumber}"
-} else {
- puts "OK ${BugNumber}"
-}
+++ /dev/null
-puts "============"
-puts "OCC16119"
-puts "============"
-puts ""
-#######################################################################
-# Bug in GeomFill_Coons algorithm
-#######################################################################
-
-set BugNumber OCC16119
-
-restore [locate_data_file OCC16119-c1.draw] c1
-restore [locate_data_file OCC16119-c2.draw] c2
-restore [locate_data_file OCC16119-c31.draw] c31
-restore [locate_data_file OCC16119-c32.draw] c32
-restore [locate_data_file OCC16119-c41.draw] c41
-restore [locate_data_file OCC16119-c42.draw] c42
-restore [locate_data_file OCC16119-cv.draw] cv
-
-fillcurves s11 c1 c41 cv c31
-fillcurves s12 cv c42 c2 c32
-
-svalue s11 .5 .5 x1 y1 z1 dux1 duy1 duz1 dvx1 dvy1 dvz1
-svalue s12 .5 .5 x2 y2 z2 dux2 duy2 duz2 dvx2 dvy2 dvz2
-
-set deltaX [dval dvx1-dvx2]
-set deltaY [dval dvy1-dvy2]
-set deltaZ [dval dvz1-dvz2]
-
-checkreal "deltaX" ${deltaX} -3.5527136788005009e-015 0 0.001
-checkreal "deltaY" ${deltaY} -3.5527136788005009e-015 0 0.001
-checkreal "deltaZ" ${deltaZ} 8.8817841970012523e-016 0 0.001
+++ /dev/null
-puts "============"
-puts "OCC16833"
-puts "============"
-puts ""
-#######################################################################
-# Error in Coons algorithm
-#######################################################################
-
-set BugNumber OCC16833
-
-restore [locate_data_file OCC16833-c1.draw] c1
-restore [locate_data_file OCC16833-c2.draw] c2
-restore [locate_data_file OCC16833-c3.draw] c3
-restore [locate_data_file OCC16833-c4.draw] c4
-
-set mistake 0
-if [catch { fillcurves result c1 c2 c3 c4 } res] {
- set mistake 1
- puts "Faulty ${BugNumber}: filling problem"
-} else {
- puts "Filling ${BugNumber} OK"
- set What [whatis result]
- if { [regexp "surface" $What] != 1 } {
- set mistake 1
- } else {
- set mistake 0
- }
-}
-
-# Resume
-puts ""
-if { ${mistake} != 0 } {
- puts "Faulty ${BugNumber}"
-} else {
- puts "OK ${BugNumber}"
-}
-