0030346: Modeling Algorithms - BRepPrimAPI_MakeRevol throws "BRepSweep_Translation...
[occt.git] / tests / bugs / modalg_7 / bug29807_b3b
1 puts "========"
2 puts "0029807: Impossible to cut cone from prism"
3 puts "========"
4 puts ""
5
6 restore [locate_data_file bug29807-obj.brep] b1
7 restore [locate_data_file bug29807-tool.brep] b2
8
9 trotate b2 +23.85857157145715500000 +12.00000000000000000000 +5.50000000000000000000 7 -7.14142842854285 0 -5 
10 removeloc b2 b2
11
12 explode b2 v
13 settolerance b2_2 1.0e-7
14
15 checkshape b2
16
17 bclearobjects
18 bcleartools
19 baddobjects b1
20 baddtools b2
21 bfillds
22
23 # CUT operation
24 bbop result 2
25
26 savehistory ResHist
27
28 checkshape result
29 checkprops result -v 9465.07 -s 4012.74
30 checknbshapes result -face 9 -wire 9
31
32 if {[regexp "Faulties" [bopargcheck result]]} {
33   puts "Error: bopargcheck has found some faulties in result"
34 }
35
36 explode b2 f
37 modified reshm ResHist b2_2
38
39 checknbshapes reshm -face 2
40
41 foreach a [explode reshm f] {
42   # Every modified face must contain degenerated edge
43   
44   if { ![regexp {degenerated} [dump $a] ] } {
45     puts "Error: Degenerated edge is not found"
46   }
47 }
48
49 vdisplay result
50 vsetdispmode 1
51 vviewparams -scale 52.4803 -proj 0.285421 0.0158136 0.958272 -up -0.810772 0.537155 0.232624 -at 29.6172 13.0268 3.82234 -eye 47.7439 14.0311 64.6808
52
53 if { [regexp {no triangulation} [tricheck result] ] } {
54   puts "Error: Result contains not triangulated face"
55 }
56
57 checkview -screenshot -3d -path ${imagedir}/${test_image}.png