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 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
|
puts "========"
puts "OCC232"
puts "Pick filter does NOT work for TopAbs_COMPSOLID topology"
puts "========"
vinit
OCC232
vfit
# selected point of first CompSolid
set x1 69
set y1 204
set x2 116
set y2 231
#set x3 160; set y3 257 - it's bad for lin,aki.
set x3 159
set y3 256
# selected point of second CompSolid
set x4 298
set y4 76
set x5 339
set y5 100
set x6 381
set y6 124
set Cyan_R 0
set Cyan_G 1
set Cyan_B 1
set Yellow_R 1
set Yellow_G 1
set Yellow_B 0
# There is not selection
puts "There is not selection"
catch {QAGetPixelColor $x1 $y1 $Yellow_R $Yellow_G $Yellow_B} result11
catch {QAGetPixelColor $x2 $y2 $Yellow_R $Yellow_G $Yellow_B} result12
catch {QAGetPixelColor $x3 $y3 $Yellow_R $Yellow_G $Yellow_B} result13
catch {QAGetPixelColor $x4 $y4 $Yellow_R $Yellow_G $Yellow_B} result14
catch {QAGetPixelColor $x5 $y5 $Yellow_R $Yellow_G $Yellow_B} result15
catch {QAGetPixelColor $x6 $y6 $Yellow_R $Yellow_G $Yellow_B} result16
# Move a mouse
puts "Move a mouse"
vmoveto $x2 $y2
# Second box of first CompSolid is selected
puts "Second box of first CompSolid is selected"
catch {QAGetPixelColor $x1 $y1 $Yellow_R $Yellow_G $Yellow_B} result21
catch {QAGetPixelColor $x3 $y3 $Yellow_R $Yellow_G $Yellow_B} result22
catch {QAGetPixelColor $x4 $y4 $Yellow_R $Yellow_G $Yellow_B} result23
catch {QAGetPixelColor $x5 $y5 $Yellow_R $Yellow_G $Yellow_B} result24
catch {QAGetPixelColor $x6 $y6 $Yellow_R $Yellow_G $Yellow_B} result25
if { [array get env os_type] != "" } {
set os $env(os_type)
}
if { [string compare $os "windows"] != 0 } {
catch {QAGetPixelColor $x2 $y2 $Cyan_R $Cyan_G $Cyan_B} result31
}
set IsFaulty 0
if { [regexp "Faulty" $result11] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result12] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result13] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result14] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result15] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result16] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result21] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result22] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result23] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result24] == 1 } {
set IsFaulty 1
}
if { [regexp "Faulty" $result25] == 1 } {
set IsFaulty 1
}
if { [string compare $os "windows"] != 0 } {
if { [regexp "Faulty" $result31] == 1 } {
set IsFaulty 1
}
}
if {$IsFaulty != 0} {
puts "Error : OCC232"
}
set only_screen 1
|