2 puts "Per-pixel lighting using GLSL program (Phong shading), check lighting of back faces"
5 pload MODELING VISUALIZATION
21 # take snapshot with fixed pipeline
22 vdump $::imagedir/${::casename}_OFF.png
23 set aColorB [vreadpixel 150 150 rgb name]
24 set aColorF [vreadpixel 250 250 rgb name]
25 if { "$aColorB" != "$aColorF"} { puts "Error: front/back colors are different!" }
26 set aColorFixed $aColorF
28 # activate phong shader
30 set aColorB [vreadpixel 150 150 rgb name]
31 set aColorF [vreadpixel 250 250 rgb name]
32 if { "$aColorB" != "$aColorF"} { puts "Error: front/back colors are different!" }
33 if { "$aColorF" != "$aColorFixed"} { puts "Error: colors are different!" }
34 vdump ${imagedir}/${casename}.png