mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
46 lines
1.1 KiB
Plaintext
Executable File
46 lines
1.1 KiB
Plaintext
Executable File
|
|
puts "========"
|
|
puts "OCC194"
|
|
puts "(case 1)"
|
|
puts "========"
|
|
puts ""
|
|
###############################################
|
|
##puts "Creating of 2D Rectangular ROTATED Grid WITH Lines"
|
|
##puts "(visual checking for this case is desirable)"
|
|
###############################################
|
|
|
|
v2dinit
|
|
v2dgrid Rect 500 500 200 200 45 Lines
|
|
|
|
if { [array get env os_type] != "" } {
|
|
set os $env(os_type)
|
|
}
|
|
if { [string compare $os "windows"] == 0 } {
|
|
set x1 25
|
|
set y1 360
|
|
set rd_ch 49411
|
|
set gr_ch 49411
|
|
set bl_ch 49411
|
|
} else {
|
|
set x1 25
|
|
set y1 361
|
|
set rd_ch 49803
|
|
set gr_ch 49803
|
|
set bl_ch 49803
|
|
}
|
|
set color [QAAISGetPixelColor2d ${x1} ${y1}]
|
|
regexp {RED +: +([-0-9.+eE]+)} $color full rd
|
|
regexp {GREEN +: +([-0-9.+eE]+)} $color full gr
|
|
regexp {BLUE +: +([-0-9.+eE]+)} $color full bl
|
|
|
|
set rd_int [expr int($rd * 1.e+05)]
|
|
set gr_int [expr int($gr * 1.e+05)]
|
|
set bl_int [expr int($bl * 1.e+05)]
|
|
|
|
if { ${rd_int} != ${rd_ch} || ${gr_int} != ${gr_ch} || ${bl_int} != ${bl_ch} } {
|
|
puts "Error : colors are not equal"
|
|
puts "Error : 2D Rectangular ROTATED Grid WITH Lines was NOT CREATED properly"
|
|
}
|
|
|
|
set only_screen2d 1
|