b819ae67 |
1 | puts "============" |
2 | puts "OCC27537" |
3 | puts "============" |
4 | puts "" |
5 | ###################################################### |
6 | # Incorrect number of sample points provided by GCPnts_TangentialDeflection |
7 | ###################################################### |
8 | |
9 | restore [locate_data_file bug27537.brep] result |
10 | incmesh result 0.2 |
11 | |
1f26f80b |
12 | bounding result -save xMin yMin zMin xMax yMax zMax -dump |
b819ae67 |
13 | |
14 | mkcurve c result |
15 | bounds c u1 u2 |
16 | set first [dval u1] |
17 | set last [dval u2] |
18 | |
19 | set x 0. |
20 | set y 0. |
21 | set z 0. |
22 | set param 0. |
23 | set isOk true |
24 | |
25 | set nbSamples 100 |
26 | set step [expr ($last - $first)/$nbSamples] |
27 | for {set i 0} {$i <= $nbSamples} {incr i} { |
28 | if {$i < $nbSamples} { |
29 | set param [expr $first + $i * $step] |
30 | } else { |
31 | set param $last |
32 | } |
33 | |
34 | cvalue c $param cx cy cz |
35 | set x [dval cx] |
36 | set y [dval cy] |
37 | set z [dval cz] |
1a0339b4 |
38 | if {$x < [dval xMin] || $x > [dval xMax] || $y < [dval yMin] || $y > [dval yMax] || $z < [dval zMin] || $z > [dval zMax] } { |
b819ae67 |
39 | puts "ERROR: point ($x; $y; $z) is out of bounding box" |
40 | set isOk false |
41 | } |
42 | } |
43 | |
44 | if {$isOk} { |
45 | puts "OK: all sample points inside bounding box" |
46 | } |
47 | |
48 | top; fit |
49 | checkview -screenshot -2d -path ${imagedir}/${test_image}.png |