1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-04 18:06:22 +03:00
occt/tests/bugs/vis/bug27797
kgv 1593b4eeab 0027797: Visualization - consider ZLayer properties while sorting list of picked entities
OpenGl_GraphicDriver::ZLayers() / V3d_Viewer::GetAllZLayers() now return
the layers sequence following rendering order (taking into account IsImmediate flag).

StdSelect_ViewerSelector3d::Pick() now sort result taking into account ZLayers flags.
2016-08-25 15:10:50 +03:00

34 lines
720 B
Plaintext

puts "========"
puts "Consider ZLayer properties while sorting list of picked entities"
puts "========"
pload MODELING VISUALIZATION
box b1 0 0 0 2 3 4
box b2 0 0 0 1 1 2
vertex v 100 -300 0
vclear
vinit View1
catch { vzlayer del 1 }
vzlayer add 1
vzlayer enable 1 depthclear
vaxo
vdisplay -noupdate -dispMode 1 -highMode 1 b1
vdisplay -noupdate -dispMode 1 -highMode 1 -layer 1 b2
vsetcolor -noupdate b1 RED
vsetcolor -noupdate b2 GREEN
vfit
vrotate 0.1 0 0
vmoveto 100 300
vstate
vselect 100 300
vmoveto 0 0
set aSelColor [vreadpixel 100 300 rgb name]
if { $aSelColor != "GRAY72"} { puts "Error: wrong object has been selected" }
vdisplay -dispMode 0 -osd -2d -trsfPersPos -1 1 v
vdump $imagedir/${casename}.png