075b21ec |
1 | puts "TODO OCC12345 ALL: Error : Tolerance invalid. Function FixShape works WRONGLY" |
2 | |
0e94a94e |
3 | puts "========================" |
4 | puts " OCC329 " |
5 | puts "========================" |
6 | puts "" |
7 | ########################################################### |
8 | ##fixshape command does not fix incorrect tolerance order. |
9 | ########################################################### |
10 | |
11 | restore [locate_data_file OCC329.brep] a |
12 | |
352ffd73 |
13 | checkshape a |
0e94a94e |
14 | set tol1 [maxtolerance a] |
15 | regexp { +Face +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol1 full face1 |
16 | regexp { +Edge +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol1 full edge1 |
17 | regexp { +Vertex +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol1 full vert1 |
18 | |
19 | fixshape result a 1.e-7 0.1 |
20 | |
352ffd73 |
21 | checkshape result |
0e94a94e |
22 | set tol2 [ maxtolerance result] |
23 | regexp { +Face +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full face2 |
24 | regexp { +Edge +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full edge2 |
25 | regexp { +Vertex +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full vert2 |
26 | |
27 | if { ${face2} > ${face1} || ${edge2} > ${edge1} || ${vert2} > ${vert1} } { |
28 | puts "Error : Tolerance invalid. Function FixShape works WRONGLY" |
29 | } else { |
30 | puts "Tolerance valed. Function FixShape works CORRECTLY" |
31 | } |
32 | |
33 | set 2dviewer 1 |
34 | |
35 | |