0024130: Implementing ray tracing visualization core
[occt.git] / tests / bugs / vis / bug24224
1 puts "==========="
2 puts "OCC24224"
3 puts "==========="
4 puts ""
5 ##########################################################################
6 # Suspicious logics in changing clipping planets at OpenGL_Structure
7 ##########################################################################
8
9 ## centre rectangle
10 set x1_coord 150
11 set y1_coord 250
12
13 ## right rectangle
14 set x2_coord 255
15 set y2_coord 320
16
17 ## left rectangle
18 set x3_coord 73
19 set y3_coord 150
20
21 vinit
22 box b1 0 0 0 10 10 10
23 box b2 30 0 0 10 40 10
24 box b3 -30 0 0 20 20 20
25 vsetdispmode 1
26 vdisplay b1 b2 b3
27 vfit
28
29 ## test view-level clipping
30 vclipplane create pln1
31 vclipplane change pln1 equation 0 1 0 -5
32 vclipplane change pln1 capping on
33 vclipplane change pln1 capping color 0.9 0.9 0.9
34 vclipplane set pln1 view Driver1/Viewer1/View1
35
36 checkcolor $x1_coord $y1_coord 0.9 0.9 0.9
37 checkcolor $x2_coord $y2_coord 0.9 0.9 0.9
38
39 ## test sharing of planes between view and object
40 vclipplane set pln1 object b1
41
42 ## test object-level clipping
43 vclipplane create pln2
44 vclipplane change pln2 equation -0.707 0.707 0 -25
45 vclipplane change pln2 capping on
46 vclipplane change pln2 capping color 0.5 0.5 0.9
47 vclipplane change pln2 capping hatch on
48 vclipplane set pln2 object b3
49
50 checkcolor $x3_coord $y3_coord 0.5 0.5 0.9
51
52 set only_screen 1
53
54
55