3306fdd9 |
1 | puts "========" |
2 | puts "0029807: Impossible to cut cone from prism" |
3 | puts "========" |
4 | puts "" |
5 | |
6 | puts "TODO OCC29883 ALL: Error in res_2: T=0" |
7 | puts "TODO OCC29883 ALL: Error: 0 vertices are expected but 2 are found" |
8 | puts "TODO OCC29883 ALL: Error : is WRONG because number of VERTEX entities in shape \"result\" is 3" |
9 | |
10 | foreach a [directory res*] {unset $a} |
11 | |
12 | binrestore [locate_data_file bug29807_f1.bin] f1 |
13 | binrestore [locate_data_file bug29807_f2.bin] f2 |
14 | |
15 | mksurface s1 f1 |
16 | mksurface s2 f2 |
17 | |
18 | trim s1 s1 |
19 | trim s2 s2 |
20 | |
21 | intersect res s1 s2 1.0e-4 |
22 | |
23 | set che [whatis res] |
24 | set ind [string first "3d curve" $che] |
25 | if {${ind} >= 0} { |
26 | #Only variable "res" exists |
27 | renamevar res res_1 |
28 | } |
29 | |
30 | bclearobjects |
31 | bcleartools |
32 | |
33 | set ic 1 |
34 | set AllowRepeat 1 |
35 | while { $AllowRepeat != 0 } { |
36 | set che [whatis res_$ic] |
37 | set ind [string first "3d curve" $che] |
38 | if {${ind} < 0} { |
39 | set AllowRepeat 0 |
40 | } else { |
41 | |
42 | bounds res_$ic U1 U2 |
43 | |
44 | if {[dval U2-U1] < 1.0e-20} { |
45 | puts "Error: Wrong curve's range!" |
46 | } |
47 | |
48 | xdistcs res_$ic s1 U1 U2 100 2.0e-7 |
49 | xdistcs res_$ic s2 U1 U2 100 2.0e-7 |
50 | |
51 | mkedge ee res_$ic |
52 | baddobjects ee |
53 | incr ic |
54 | } |
55 | } |
56 | |
57 | bfillds |
58 | bbuild result |
59 | |
60 | smallview |
61 | don result* |
62 | fit |
63 | |
64 | # Check gaps between edges in ce |
65 | checksection result -r 0 |
66 | checkmaxtol result -min_tol 2.0e-7 |
67 | |
68 | checknbshapes result -edge 2 -vertex 2 |
69 | |
70 | checkview -screenshot -2d -path ${imagedir}/${test_image}.png |