Hey everyone,
I'm having a bit of trouble trying to create and modify the rgbPP of a
particle system. I've tried every way possible, but can't seem to get the
result I'm looking for.
I have a list of positions and colors that I'd like to create a particle
object with. I'm having no trouble with the positions, it's the rgbPP that
seems to be a pain. Is it possible to do this via the emit command?
points = [(0,0,0), (1,1,1), (2,2,2)]
colors = [(0,1,0), (0,0,1), (1,1,1)]
pShape = particle()
mel.eval('addAttr -ln "rgbPP" -dt vectorArray %s' % pShape[1].name())
mel.eval('addAttr -ln "rgbPP0" -dt vectorArray %s' % pShape[1].name())
emit(object=pShape[0].name(), pos=points, attribute=('rgbPP'),
vectorValue=colors)
Also, I finally fell back onto mel for adding the rgbPP, I couldn't seem to
get the maya stuff working.
I know that I could iterate over all of the particle and set their rgbPP,
but I'm trying to do it in 1 shot. Do I need to use the API to accomplish
this?
Thanks,
Justin
--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/python_inside_maya
-~----------~----~----~----~------~----~------~--~---