File: bug23863

package info (click to toggle)
oce 0.15-5
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 302,472 kB
  • ctags: 210,903
  • sloc: cpp: 1,165,052; ansic: 75,256; sh: 11,901; tcl: 4,488; python: 2,867; makefile: 337; perl: 37; csh: 12
file content (38 lines) | stat: -rwxr-xr-x 1,175 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
puts "================"
puts "OCC23863"
puts "================"
puts ""
#######################################################################
# Wrong distance value between circle and cylinder
#######################################################################

pcylinder b1 10 10
explode b1 f
copy b1_1 b1
circle b2 0 10 10 1 0 0 5
mkedge b2 b2

distmini d b1 b2

regexp {([-0-9.+eE]+)$} [dump d_val] full dist
regexp { +Vertex +: +Min +[-0-9.+eE]+ +Max +([-0-9.+eE]+)} [ maxtolerance d ] full toler
set good_dist 0
if { [expr abs( ${dist} - ${good_dist} )] > ${toler} } {
    puts "Faulty : the distanse is ${dist}. It is bad value"
}

regexp { +Point 3D : +([-0-9.+eE]+), +([-0-9.+eE]+), +([-0-9.+eE]+)} [ dump d ] full x y z
set good_x 0
set good_y 10
set good_z 5
if { [expr abs( ${x} - ${good_x} )] > ${toler} } {
    puts "Faulty : the x coordinate of the point is ${x}. It is bad value"
}
if { [expr abs( ${y} - ${good_y} )] > ${toler} } {
    puts "Faulty : the y coordinate of the point is ${y}. It is bad value"
}
if { [expr abs( ${z} - ${good_z} )] > ${toler} } {
    puts "Faulty : the z coordinate of the point is ${z}. It is bad value"
}

set 2dviewer 1