0027986: Visualization - AIS_InteractiveContext::SetLocation() does not update dynami...
[occt.git] / tests / bugs / vis / bug25552
CommitLineData
a272ed94 1puts "============"
2puts "CR25552"
3puts "Provide the way to hide objects within different Views of the one Viewer"
4puts "============"
5puts ""
6
7set aSubShapeTriang $imagedir/${casename}_subshape_triangulation.png
8set aShapeTriang $imagedir/${casename}_shape_triangulation.png
9set aDiff $imagedir/${casename}_diff.png
10
11vinit View1
12vclear
13vaxo
14vsetdispmode 1
15
16vinit View2
17vclear
18vaxo
19vsetdispmode 1
20
21box b1 0 0 0 1 2 3
22box b2 3 0 0 2 3 1
23box b3 0 3 0 2 3 1
24
25vdisplay b1 b3
26# b2 should be displayed only in View2, but not in View1
27vdisplay -inview b2
28#vdisplay b2
29vaspects -noupdate b1 -setcolor RED
30vaspects -noupdate b2 -setcolor GREEN
31vfit
32# b1 should be displayed only in View1
33verase -inview b1
f751596e 34vmoveto 250 347
a272ed94 35
36set aColorV2B1 [vreadpixel 50 250 rgb name]
37if { $aColorV2B1 != "BLACK" } {
38 puts "Error: box b1 (red) should NOT be visible in View2!"
39}
40
41set aColorV2B2 [vreadpixel 200 350 rgb name]
42if { $aColorV2B2 != "GREEN3" } {
43 puts "Error: box b2 (green) should be visible in View2!"
44}
45
46set aColorV2B3 [vreadpixel 250 200 rgb name]
47if { $aColorV2B3 != "DARKGOLDENROD3" } {
48 puts "Error: box b3 (goldenrod) should be visible in View2!"
49}
50vdump $imagedir/${casename}_v2.png
51
52vactivate View1
53vfit
54set aColorV1B1 [vreadpixel 50 250 rgb name]
55if { $aColorV1B1 != "RED3" } {
56 puts "Error: box b1 (red) should be visible in View1!"
57}
58
59set aColorV1B2 [vreadpixel 200 350 rgb name]
60if { $aColorV1B2 != "BLACK" } {
61 puts "Error: box b2 (green) should NOT be visible in View1!"
62}
63
64set aColorV1B3 [vreadpixel 250 200 rgb name]
65if { $aColorV1B3 != "DARKGOLDENROD3" } {
66 puts "Error: box b3 (goldenrod) should be visible in View1!"
67}
68vdump $imagedir/${casename}_v1.png