File: bug29972_1

package info (click to toggle)
opencascade 7.5.1%2Bdfsg1-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 290,544 kB
  • sloc: cpp: 1,190,524; tcl: 15,703; cs: 5,173; java: 1,557; ansic: 1,174; sh: 901; xml: 699; perl: 54; makefile: 27
file content (65 lines) | stat: -rw-r--r-- 1,146 bytes parent folder | download
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
puts "========"
puts "OCC29972: Intersection curve has a weird gap in the middle of it"
puts "========"
puts ""

set GoodNbCurves 2

foreach a [directory res*] {unset $a}

restore [locate_data_file bug29972_s1.draw] s1 
cylinder s2 -120 54.2955104312028 -116 1 0 0 0 0 -1 28

intersect res s1 s2

set che [whatis res]
set ind [string first "3d curve" $che]
if {${ind} >= 0} {
  #Only variable "res" exists
  renamevar res res_1
}

bclearobjects
bcleartools

set ic 1
set AllowRepeat 1
while { $AllowRepeat != 0 } {
  set che [whatis res_$ic]
  set ind [string first "3d curve" $che]
  if {${ind} < 0} {
    set AllowRepeat 0
  } else {
   
    bounds res_$ic U1 U2
    
    if {[dval U2-U1] < 1.0e-9} {
      puts "Error: Wrong curve's range!"
    }
    
    xdistcs res_$ic s1 U1 U2 100 2.0e-6
    xdistcs res_$ic s2 U1 U2 100 2.0e-6
    
    mkedge ee res_$ic
    baddobjects ee
    
    incr ic
  }
}

# Check of gaps between intersection curves
bfillds
bbuild rs

checknbshapes rs -edge $GoodNbCurves
checksection rs -r 0

smallview
don res_*

fit
don s1 s2
clpoles s1
disp res_*

checkview -screenshot -2d -path ${imagedir}/${test_image}.png