[vtkusers] Iteration help
Shiva Bissoon
sbissoo2 at hotmail.com
Wed Apr 25 15:45:37 EDT 2001
Hi all,
I am having some problems with iteration and I am hoping someone can assist.
I am trying to create some random integers for positions of x, y and
z.However, it just doesn't seem to recognize the parameters.if someone can
run this and perhaps give some advise, I would be most grateful.
Thanks in advance,
Shiva Bissoon
##create the actor--add iteration here!!!
#here is the test iteration
for {set i 1} {$i < 4} {incr i} {
vtkMath math$i
set $x [math$i Random -2 2]
set $y [math$i Random -1 1]
set $z [math$i Random -1 1]
vtkActor contActor$i
contActor$i SetMapper contMapper
contActor$i SetOrigin 1 10 0
contActor$i SetPosition $x $y $z
#contActor SetPosition 0.3 .5 .5
[contActor$i GetProperty] SetColor 1 0 0
# contActor RotateX 10
ren1 AddActor contActor$i
renWin Render
}
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
More information about the vtkusers
mailing list