0024696: Lower performance of the new Edge/Edge intersection algorithm
[occt.git] / tests / caf / presentation / K2
CommitLineData
40093367 1#INTERFACE CAF
2# Presentation attributes
3#
4# Testing attribute: TPrsStd_AISPresentation
5#
6# Testing command: AISUnset
7#
8
9puts "caf003-K2"
10
11# Create two boxis
12box aBox1 100 200 300
13set aLabel1 0:2
14SetShape D ${aLabel1} aBox1
15
16box aBox2 50 50 0 100 200 300
17set aLabel2 0:3
18SetShape D ${aLabel2} aBox2
19
20# Initialize 3D viewer
21AISInitViewer D
22
23# Add AISPresentation attribute with parameter NS
24AISSet D ${aLabel1} NS
25AISSet D ${aLabel2} NS
26
27# Set shading mode
28vsetdispmode 1
29
30# Set a color of the second shape as NOC_GREEN
31AISColor D ${aLabel2} 229
32
33# Display presentation of NamedShape in the viewer
34AISDisplay D ${aLabel1}
35AISDisplay D ${aLabel2}
36
37# Close/Open transaction
38NewCommand D
39
40# Unset TPrsStd_AISPresentation attribute from ${aLabel1}
41AISUnset D ${aLabel1}
42
43# Close/Open transaction
44NewCommand D
45
46# Undo
47Undo D
48
49# Update the viewer
50AISRepaint D
51
52###puts "There are two boxis"
53
54# Redo
55Redo D
56
57# Update the viewer
58AISRepaint D
59
60# 15. Get current color of ${aLabel1}
61set IsDone [catch {set aColor [lindex [AISColor D ${aLabel1}] 0]} aResult]
62if { ${IsDone} == 0 } {
63 puts ${aResult}
64 puts "AISUnset command: Error"
65 return
66} else {
67 puts "AISUnset command: OK"
68}
69
70puts "There is one box"