f6470bf151667f93fbdde15ffc316f4a96b3b699
[occt.git] / tests / v3d / glsl / rendscale
1 puts "========"
2 puts "Rendering resolution scale factor"
3 puts "========"
4
5 set aFontFile ""
6 catch { set aFontFile [locate_data_file DejaVuSans.ttf] }
7
8 pload MODELING VISUALIZATION
9
10 set aLabelFont "Arial"
11 if { "$aFontFile" != "" } {
12   vfont add "$aFontFile" SansFont
13   set aLabelFont "SansFont"
14 }
15
16 box b 1 2 3
17 vclear
18 vinit View1
19 vdisplay b
20 vfit
21 vpoint p 0 0 0
22 vzbufftrihedron
23 vdrawtext t Text2d -font $aLabelFont
24 vtrihedron tt
25 vdisplay -trsfPers zoom -trsfPersPos 1 0 0 tt
26 text2brep ttl "Top-Left" -font $aLabelFont -height 30 -pos 0 -30 0
27 vdisplay  ttl -2d topLeft -dispMode 1
28 vcolorscale cs -demo
29
30 vrenderparams -rendScale 1
31 vdump $::imagedir/${::casename}_100.png
32
33 vrenderparams -rendScale 0.5
34 vdump $::imagedir/${::casename}_050.png
35
36 vrenderparams -rendScale 0.75
37 vdump $::imagedir/${::casename}_075.png
38
39 vrenderparams -rendScale 2
40 vdump $::imagedir/${::casename}_200.png