1 puts "================"
3 puts "================"
5 #######################################################################################
6 # XCAFPrs_AISObject does not support transparency
7 ######################################################################################
16 #Set NamedShape attribute
19 SetShape D ${Label} Box
21 # Initialize 3D viewer
24 # Add AISPresentation attribute with parameter NS
30 # Display presentation of NamedShape in the viewer
33 # Close/Open transaction
36 set list [OCC1031_AISMaterial D ${Label}]
37 regexp {Material = ([-0-9.+eE]+)} $list full AISMaterial1
39 # Set a material of the shape as NOM_COPPER
41 OCC1031_AISMaterial D ${Label} ${CopperMaterial}
43 set list [OCC1031_AISMaterial D ${Label}]
44 regexp {Material = ([-0-9.+eE]+)} $list full AISMaterial2
46 # Close/Open transaction
49 set list [OCC1032_AISWidth D ${Label}]
50 regexp {Width = ([-0-9.+eE]+)} $list full AISWidth1
54 OCC1032_AISWidth D ${Label} ${Width}
56 set list [OCC1032_AISWidth D ${Label}]
57 regexp {Width = ([-0-9.+eE]+)} $list full AISWidth2
59 # Close/Open transaction
62 set list [OCC1029_AISTransparency D ${Label}]
63 regexp {Transparency = ([-0-9.+eE]+)} $list full Transparency1
67 XSetTransparency D ${Transparency} ${Label}
69 set list [OCC1029_AISTransparency D ${Label}]
70 regexp {Transparency = ([-0-9.+eE]+)} $list full Transparency2
77 puts "AISMaterial1 = ${AISMaterial1}"
78 puts "AISMaterial2 = ${AISMaterial2}"
79 set DefaultAISMaterial 0
81 if { ${AISMaterial1} != ${DefaultAISMaterial} } {
82 puts "Default material is wrong: Error"
85 if { ${AISMaterial2} != ${CopperMaterial} } {
86 puts "OCC1031_AISMaterial command: Error"
91 puts "AISWidth1 = ${AISWidth1}"
92 puts "AISWidth2 = ${AISWidth2}"
94 if { ${AISWidth1} != ${DefaultAISWidth} } {
95 puts "Default width is wrong: Error"
98 if { ${AISWidth2} != ${Width} } {
99 puts "OCC1032_AISWidth command: Error"
103 # Check the transparency
104 puts "Transparency1 = ${Transparency1}"
105 puts "Transparency2 = ${Transparency2}"
106 set DefaultAISTransparency 0
107 if { ${Transparency1} != ${DefaultAISTransparency} } {
108 puts "Default transparency is wrong: Error"
112 if { ${Transparency2} != ${Transparency} } {
113 puts "XSetTransparency command: Error"
118 if { ${status} == 0} {
124 checkview -display result -3d -path ${imagedir}/${test_image}.png