0f93917a3757b50f7fc94a31954a87c46b66e88c
[occt.git] / tests / bugs / vis / bug30630_3
1 puts "=================================================================================="
2 puts "0030630: Visualization - wrong visualization of shape with mirrored transformation"
3 puts "Check that solid with mirrored transformation is displayed as turned out"
4 puts "=================================================================================="
5
6 pload MODELING VISUALIZATION
7 vclear
8 vinit View1
9 vaxo
10 vrotate 3 0 0
11 vcamera -persp
12
13 # Simple box
14 box b 1 1 1
15 vdisplay -dispMode 1 b
16 vaspects b -setBackFaceColor RED
17 vfit
18 vdump $imagedir/${casename}_simple.png
19 verase b
20
21 # Box with mirror transformation
22 box a 1 1 1
23 bmirror a 0 0 0 1 0 0
24 vdisplay -dispMode 1 a
25 vaspects a -setBackFaceColor RED
26 vfit
27 box aa -0.5 0.5 0.5 0.1 0.1 0.1
28 vdisplay -dispMode 1 aa
29 vsetcolor aa BLUE
30 vdump $imagedir/${casename}_mirror.png
31 if { [vreadpixel 195 220 rgb name] != "BLUE2" } { puts "Error: mirrored box should look inside out" }
32 verase a
33
34 # Box with mirror transformation and reversed face
35 box c 1 1 1
36 bmirror c 0 0 0 1 0 0
37 orientation c R
38 vdisplay -dispMode 1 c
39 vaspects c -setBackFaceColor RED
40 vfit
41 vdump $imagedir/${casename}_mirrev.png
42 if { [vreadpixel 195 220 rgb name] == "BLUE2" } { puts "Error: revered mirrored box should NOT look inside out" }