0031682: Visualization - Prs3d_ShadingAspect::SetTransparency() has no effect with...
[occt.git] / tests / v3d / glsl / phong_fuse2
CommitLineData
12381341 1puts "========"
2puts "Per-pixel lighting using GLSL program (Phong shading)"
3puts "========"
4
5# import model
6restore [locate_data_file occ/fuse.brep] f
7tclean f
8
9# draw box
12381341 10vclear
8e0a2b19 11vclose ALL
12vinit View1
4c513386 13vdefaults -absDefl 0.5
12381341 14vsetdispmode 1
15vaxo
16vdisplay f
17vfit
18vrotate -0.5 0.0 0.0
19vfit
20
21# setup lights
22vlight delete 0
23vlight delete 0
24vlight delete 0
25vlight delete 0
26vlight delete 0
27vlight add ambient color WHITE
28vlight add directional dir 1 0 0 color GREEN headlight 1
29vlight add directional dir -1 0 0 color RED1 headlight 1
30
31# take snapshot with fixed pipeline
32vdump $::imagedir/${::casename}_OFF.png
33vshaderprog f phong
34vdump $::imagedir/${::casename}_ph1.png
35
36vclear
37vdisplay f
38vshaderprog f phong
39vdump $::imagedir/${::casename}_ph2.png
40vmoveto 250 250