puts "============" puts "CR26344" puts "============" puts "" ########################################################################################## puts "Visualization - provide a support of zoom persistent selection" ########################################################################################## vclear vclose ALL vinit View1 w=409 h=409 vtrihedron tri vpan 50 50 box b1 25 25 25 box b2 25 25 25 box b3 100 100 100 box b4 100 100 100 box b5 100 100 100 # 1) Zoom persistence vpoint p1 200 200 200 vdisplay b1 -dispMode 1 -highMode 1 -trsfPers zoom -trsfPersPos 200 200 200 vdisplay b2 -dispMode 1 -highMode 1 -trsfPers zoom -trsfPersPos 200 200 200 vsetlocation b2 -25 -25 -25 vselect 0 0 vselect 387 77 if { [vreadpixel 387 77 rgb name] != "GRAY66" } { puts "Error picking zoom persistence object(s)" } vselect 0 0 vselect 330 120 400 50 if { [vreadpixel 387 77 rgb name] != "GRAY66" || [vreadpixel 352 96 rgb name] != "GRAY66" } { puts "Error selecting zoom persistence object(s)" } # 2) Rotate persistence vdisplay b3 -dispMode 1 -highMode 1 -trsfPers rotate -trsfPersPos -200 -200 -200 vsetmaterial b3 PLASTIC vselect 0 0 vselect 160 200 if { [vreadpixel 160 180 rgb name] != "WHITE" } { puts "Error picking rotate persistence object" } vselect 0 0 vselect 130 230 190 170 if { [vreadpixel 160 180 rgb name] != "WHITE" } { puts "Error selecting rotate persistence object" } # 3) Pan persistence vdisplay b4 -dispMode 1 -highMode 1 -trsfPers pan vselect 0 0 vselect 233 188 if { [vreadpixel 233 188 rgb name] != "GRAY66" } { puts "Error picking pan persistence object" } vselect 0 0 vselect 200 230 270 140 if { [vreadpixel 233 188 rgb name] != "GRAY66" } { puts "Error selecting pan persistence object" } # 4) Trihedron persistence vdisplay b5 -dispMode 1 -highMode 1 -trsfPers trihedron -trsfPersPos -1 -1 62 vselect 0 0 vselect 132 300 if { [vreadpixel 132 300 rgb name] != "GRAY66" } { puts "Error picking trihedron persistence object" } vselect 0 0 vselect 50 223 235 395 if { [vreadpixel 132 300 rgb name] != "GRAY66" } { puts "Error selecting trihedron persistence object" } vselect 50 380 400 50 checkview -screenshot -3d -path ${imagedir}/${test_image}.png