Files
OCCT/tests/v3d/shadows/dir3
kgv e70625d6b1 0030640: Visualization, Graphic3d_Camera - add option creating Projection matrix with [0,1] depth range
Added new property Graphic3d_Camera::IsZeroToOneDepth() and OpenGl_Caps::useZeroToOneDepth
for activating [0,1] depth range instead of [-1,1] range using glClipControl() within OpenGL 4.5+.
2021-03-05 17:41:27 +03:00

33 lines
856 B
Plaintext

puts "========"
puts "0030640: Visualization, Graphic3d_Camera - add option creating Projection matrix with 0 to 1 depth range"
puts "Test shadow map from a single directional light source on a box geometry."
puts "========"
pload MODELING VISUALIZATION
if { $::tcl_platform(os) == "Darwin" } { vcaps -core }
vcaps -depthZeroToOne 1
box b 1 2 3
box bb -5 -5 0 10 10 0 -preview
vgldebug 1
vcaps -core
vcaps -vsync 0
vclear
vinit View1
vrenderparams -shadingModel PHONG
vdisplay -dispMode 1 b bb
vaspects bb -material STONE
vfit
vselect 250 200
vlight -change 0 -castShadows 1 -direction 1 1 -1 -head 0
vraytrace 1
vdump $::imagedir/${::casename}_raytrace.png
vraytrace 0
vrenderparams -shadingModel phong
vrenderparams -shadowMapBias 0.01
vdump $::imagedir/${::casename}_phong.png
vrenderparams -shadingModel pbr
vdump $::imagedir/${::casename}_pbr.png