tboyce
2015年9月23日 18:18:45
I created an otl that takes in source points and copies geometry created inside the otl to those points.
When brought into maya, and a normal particle is attached it works fine, but if nparticles are attached it does not copy the geometry to those particles.
Is there something I have to do with the nparticles to get them to work?
awong
2015年9月24日 11:44:40
That should work. The only thing I can think of is that you need to do a “sync” at a frame where there are actually particles (i.e. the asset actually has output), so that a mesh node is created on the Maya side. However, this applies to both particle and nParticle types.
tboyce
2015年9月24日 15:58:42
Ok, I didn't know about syncing but that worked like a charm.
I have a second question though, I'm trying to drive a channel based on the nparticle's age.
My initial attempt using $AGE doesn't seem to be working - is the nparticles' age remapped into houdini's $AGE attribute? Is there some other way I need to be going about this?
Thanks for the help!
awong
2015年9月24日 16:18:10
Hm, looks like the age attribute is not being mapped to Houdini Engine. The plugin uses the MEL “particle -q -perParticleDouble nParticleShape1” to list out the per-particle attributes to map. However, that list doesn't include age for some reasons. Let me look into adding it. It should be fairly straightforward.
tboyce
2015年9月24日 16:21:22
That would explain it!
Thanks for looking into it and adding that support!
awong
2015年9月24日 16:26:22
Having the age attribute doesn't mean you can access it right away with the $AGE variable. You would have to use attribCreate SOP to map the “age” attribute to the “AGE” variable.
Also, if you use Debugging -> View Assets in Houdini, you can see a snapshot of the Houdini Engine state. This is useful for debugging. For example, this lets you see what data is available in the input geometry.
tboyce
2015年9月24日 16:49:45
Ok, good to know. Thanks!
awong
2015年9月24日 19:15:27
I've made the changes to include the “age” attribute. It should be in tomorrow's build (14.0.466).
tboyce
2015年9月25日 08:44:18
Awesome!
I got a work-around by connecting the nparticle age to its color (though I found you have to make it's base color black because for whatever reason Maya doesn't obey this linkage on the frame it is born).
Thanks Andrew!
awong
2015年9月25日 09:41:56
The plugin will actually convert other per-particle attributes as well. So instead of connecting to color, you could alo create a custom attribute and connect age to that.