1 puts "========================"
4 puts "========================"
6 ####################################
7 ## Big tolerance after commmand fixshape r a 1.e-7 1
8 ####################################
12 restore [locate_data_file OCC547.brep] a
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
19 fixshape result a 1.e-7 1
21 set tol2 [ maxtolerance result]
22 regexp { +Face +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full face2
23 regexp { +Edge +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full edge2
24 regexp { +Vertex +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} $tol2 full vert2
26 if { ${face2} > ${face1} || ${edge2} > ${edge1} || ${vert2} > ${vert1} } {
27 puts "Error : Tolerance invalid. Function FixShape works WRONGLY"
29 puts "Tolerance valed. Function FixShape works CORRECTLY"
32 checkview -display result -2d -path ${imagedir}/${test_image}.png