0029807: [Regression to 7.0.0] Impossible to cut cone from prism
[occt.git] / tests / bugs / modalg_2 / bug5805_47
1
2 puts "============"
3 puts "OCC5805"
4 puts "============"
5 #######################################################################
6 # BRepOffsetAPI_MakeThickSolid behaves unstably and produces very different results.
7 #######################################################################
8 cpulimit 8000
9 set BugNumber OCC5805
10
11 # pbsplinecurve1
12 pbsplinecurve pbc1 3 9 0 1 1 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 -1 0 0 1 -2 2 0 1 0 1 0 1 2 2 0 1 1 0 0 1 2 -2 0 1 0 -1 0 1 -2 -2 0 1
13 mkedge e1 pbc1
14 wire UpCover e1
15
16 # pbsplinecurve1
17 copy e1 e2
18 ttranslate e2 0 0 20
19 tscale e2 0 0 0 2
20 wire BottomCover e2
21
22 set issolid 1
23 set isruled 1
24 if [catch { thrusections s ${issolid} ${isruled} UpCover BottomCover } catch_result] {
25    puts "Faulty ${BugNumber} : thrusections is wrong"
26    
27 }
28
29 set distance -0.1
30 catch { OFFSETSHAPE $distance {s_2} $calcul $type }
31
32
33 checkprops result -s 1673.57
34 checkshape result
35
36 checknbshapes result -vertex 4 -edge 6 -wire 6 -face 5 -shell 1 -solid 1 -compsolid 0 -compound 0 -shape 23
37
38 set index [lsearch [whatis s] Closed]
39 if {$index == -1} {
40   puts "Faulty ${BugNumber} : s is not Closed shape"
41   
42 }
43
44 set index [lsearch [whatis result] Closed]
45 if {$index == -1} {
46   puts "Faulty ${BugNumber} : result is not Closed shape"
47   
48 }
49
50
51 checkview -display result -2d -path ${imagedir}/${test_image}.png