Heyo! Yeah, still in Vancouver. Been here a year now. You?
I don't think the particle command can set the color of every particle at once given a different color for each particle. I was hoping not to iterate over the entire system setting each particle individually, I'm handling 4+million particles. -- iPhone Justin Rosen On Jul 1, 2009, at 8:26 AM, Dave Nunez <[email protected]> wrote: > Hey dude, whats going on.. long time. > > > you can set the pt colours using the particle command. check the > docs. > > ie > > particle -e -or 2 -at rgbPP -vv 1 0 0 particleShape1 ; > > add your attrs first of course. > > hth, -d > > Are you still in Vancouver btw ? > > > On Tue, Jun 30, 2009 at 9:20 PM, Justin Rosen > <[email protected]> wrote: > 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 > > > > > > -- > When things get too complicated, it sometimes makes sense to stop > and wonder: Have I asked the right question? > -Enrico Bombieri > > > --~--~---------~--~----~------------~-------~--~----~ http://groups.google.com/group/python_inside_maya -~----------~----~----~----~------~----~------~--~---
