0025952: Wrong intersection curve
[occt.git] / tests / lowalgos / intss / bug25952_3
CommitLineData
9d083161 1puts "========"
2puts "0025952: Wrong intersection curve"
3puts "========"
4puts ""
5
6puts "TODO OCC26510 ALL: Error: 1 curve is expected but 0 ones are found"
7
8set aGoodNbCurves 1
9
10restore [locate_data_file bug25952_shape.brep] q
11explode q
12copy q_1 b1
13copy q_2 b2
14
15mksurface s1 b1
16mksurface s2 b2
17
18intersect res s1 s2
19
20set che [whatis res]
21set ind [string first "3d curve" $che]
22if {${ind} >= 0} {
23 #Only variable "res" exists
24 renamevar res res_1
25}
26
27set ic 1
28set AllowRepeat 1
29while { $AllowRepeat != 0 } {
30 set che [whatis res_$ic]
31 set ind [string first "3d curve" $che]
32 if {${ind} < 0} {
33 set AllowRepeat 0
34 } else {
35 lappend CurvesList res_$ic
36 CheckLoops res_$ic
37 incr ic
38 }
39}
40
41set ic [expr $ic - 1]
42
43if { $ic != $aGoodNbCurves } {
44 puts "Error: $aGoodNbCurves curve is expected but $ic ones are found"
45} else {
46 CheckIntersectionResult s1 s2 $CurvesList 100 2.0e-7 2.0e-7
47}
48
49smallview
50don res_*
51fit
52
53checkview -screenshot -2d -path ${imagedir}/${test_image}.png