Adjusting testing cases for current state of OCCT
[occt.git] / tests / bugs / modalg_2 / bug22818_2
CommitLineData
b62b93ac 1puts "TODO OCC23832 ALL: Error : area by triangles differs from the actual area by"
2
809eca9d 3puts "================"
4puts "OCC22818"
5puts "================"
6puts ""
7#######################################################################################
8# Wrong triangulation of Revolution surface with slice angle <= 180 degree
9######################################################################################
10
11set BugNumber OCC22818
12
13vertex v1 0 10 0
14vertex v2 0 10 10
15vertex v3 0 5 5
16vertex v4 0 0 -10
17edge e1 v1 v2
18edge e2 v2 v3
19edge e3 v3 v1
20wire w1 e1 e2 e3
21plane pln 0 5 5 1 0 0
74f764ba 22mkface f1 pln
23add w1 f1
809eca9d 24don f1
25revol result f1 0 10 0 0 0 1 180
26checkshape result
27
74f764ba 28set square 186.072
809eca9d 29
30set nb_v_good 3
31set nb_e_good 8
32set nb_w_good 4
33set nb_f_good 4
34set nb_sh_good 1
35set nb_sol_good 1
36set nb_compsol_good 0
37set nb_compound_good 0
38set nb_shape_good 21
39
b62b93ac 40vinit
41vdisplay result
42vsetdispmode 1
43vfit
44vzfit
45
46# relative tolerance (%)
47set rel_tol 1
48set area_eps 0
49#
50puts "\nChecking triangulation area (triarea command)..."
51set rel_err [expr abs([CheckTriArea result $area_eps])]
52if { $rel_err > $rel_tol } {
53 puts "Error : area by triangles differs from the actual area by $rel_err %"
54} else {
55 if { $rel_tol > 1 && $rel_tol < 100 } {
56 puts "Error: Improvement: The current area difference is $rel_err instead of $rel_tol"
57 }
58}
59
60set only_screen 1