0027986: Visualization - AIS_InteractiveContext::SetLocation() does not update dynami...
[occt.git] / tests / bugs / vis / bug25723_1
CommitLineData
4af098ba 1puts "============"
2puts "OCC25723"
3puts "Calculate the center of rotation taking into account active selection"
4puts "============"
5puts ""
6
7set x_sel_coord 220
8set y_sel_coord 50
9
10set x_mouse_start_coord 100
11set y_mouse_start_coord 100
12
13set x_mouse_move_coord 300
14set y_mouse_move_coord 300
15
16set x_check_coord 220
17set y_check_coord 50
18
19box b1 0 0 0 10 10 10
20box b2 0 0 20 10 10 10
21box b3 0 0 -20 10 10 10
22box b4 0 0 40 10 10 10
23
24vinit View1
25vclear
26vaxo
27vsetdispmode 1
28
29# turn on solid selection
30vselmode 6 1
31vdisplay b1 b2 b3 b4
32vfit
33
34# select one (red) solid
35vselect ${x_sel_coord} ${y_sel_coord}
36
37# start rotation
38vrotate -mouseStart ${x_mouse_start_coord} ${y_mouse_start_coord} -mouseMove ${x_mouse_move_coord} ${y_mouse_move_coord}
39
40# unselect
41vselect 0 0
42
43# check color
44if {"[vreadpixel ${x_check_coord} ${y_check_coord} rgb name]" != "GOLDENROD2"} {
45 puts "Error : Rotation is not correct"
46}
47
5747059b 48checkview -screenshot -3d -path ${imagedir}/${test_image}.png