1 # Sample demonstrating assignment of colors to faces in XDE
4 #Title: Assignment of colors to faces
6 pload MODELING VISUALIZATION OCAF XDE
8 box b 0 -20 -10 100 40 20
11 trotate a_1 0 0 0 1 0 0 60
12 trotate a_2 0 0 0 1 0 0 -60
17 trotate c 0 0 0 0 1 0 90
24 trotate e 0 0 0 0 1 0 90
30 text2brep text "CAD Assistant" -font Times -height 10
31 ttranslate text 10 -4 10
38 #vsetcolor body yellow
49 for {set i 1} {$i <= 26} {incr i} {XSetColor D body_1_$i BLUE}
50 XSetColor D body_1_1 E68066
51 XSetColor D body_1_9 E68066
52 for {set i 10} {$i <= 22} {incr i} {XSetColor D body_1_$i 99B300}
53 XSetColor D core_1 1A1AFF
54 foreach ff [explode core_1 f] { XSetColor D $ff 1A1AFF ; puts "set color $ff" }
58 XDisplay -dispMode 1 D -explore
61 vbackground -color WHITE
63 #param write.iges.brep.mode 1
64 #WriteIges D d:/pencil3.igs