0030942: Draw Harness, ViewerTest - command vdefaults should abort script on unknown...
[occt.git] / tests / bugs / vis / bug25544_graytexture
1 puts "============"
2 puts "0025544: Visualization, TKOpenGl - support grayscale textures"
3 puts "============"
4 puts ""
5
6 vinit View1
7 vclear
8
9 box b 1 2 3
10 vaxo
11 vsetdispmode 1
12 vdisplay b
13 vtexture b 1 -modulate on
14 vfit
15
16 set aColorMod [vreadpixel 290 180 rgb name]
17 vdump $imagedir/${casename}_modulated.png
18
19 vtexture b 1 -modulate off
20 set aColorDec [vreadpixel 290 180 rgb name]
21 vdump $imagedir/${casename}_decal.png
22
23 if {"$aColorMod" != "GOLDENROD4"} {
24   puts "Error: wrong color with modulation ON"
25 }
26 if {"$aColorDec" != "GRAY80"} {
27   puts "Error: wrong color with modulation OFF"
28 }