Forum: Poser - OFFICIAL


Subject: Making symetrical hair in Poser?

Gurichi opened this issue on Aug 26, 2007 · 11 posts


Cage posted Mon, 27 August 2007 at 11:28 PM

Okay, I think I can do this, but not in the way I'd expected.  There will be some necessary limitations and/or complications.

PoserPython can't use its normal geometry creation methods for this, for two reasons.

  1. The normal PoserPython geometry creation/alteration routines, using Numeric arrays, will only create closed polygons. PoserPython can manipulate hair geometry, but it treats each hair as a polygon.  In the .obj/geomCustom listings, each hair is listed as a line, not a polygon (with an "l" line instead of an "f" line).  PoserPython can't create line geometry, it seems.

  2. Poser won't allow dynamic hair geometry line/poly count to be increased.  It can be decreased, but I didn't test to see what effect that might have once a hair dynamics simulation is run.  I tested this with both the PoserPython geometry methods and geometry insertion poses, and in both cases Poser simply ignored the change if it involved any increase in hair count.

I think I can do this, however, by creating a new .hr2 file which contains the new geometry.  My tests so far suggest that this should work.  But there are some complications.

  1. As far as I can tell, "show populated" should not be in use when the script is run.  We want to work with only the guide hairs.  I may be wrong about this, but I think PoserPython considers the populated hairs as part of the geometry if show populated is active.  I'll test to verify.
     

  2. Any existing .dyn dynamics run for the hair prop will be invalidated once the geometry is changed.  It's probably best not to try this with hair for which dynamics have been run.  I'll see if I can simply strip the .dyn path reference from the altered .hr2 file, but I don't know whether Poser will tolerate that.

  3. The styling tools actually alter the hair geometry and the effects of these can be mirrored effectively, but the dials (such as pull down, pull side, etc.) are listed in the .hr2 file as part of the dynamics settings and will therefore be applied globally to a new prop with altered geometry.  In the case of pull side, at least, this could affect the symmetry if these dials have been used in the styling process.  So it's probably best not to use them to style a hair prop which is to be mirrored.  I may be able to "bake" these settings into both sides of the altered geometry by using WorldVertex instead of Vertex positions when I export the new geometry.  If this works, the values for the dials should be zeroed in the altered .hr2.  I haven't yet tested to see if this idea will work, however.

So it should work, basically, but the results may be less than perfect.  :(  The script will basically delete the selected hair prop and create and load a replacement.  With any luck, I should have a first version together tomorrow.

A completely different approach might be tried, and it might be better.  If the user creates the hairs on both sides in separate groups, then styles one side, a script could easily transfer the shaping for one side to the other.  The complications so far all have to do with trying to add new geometry.  Re-shaping existing hairs shouldn't pose such problems.  Perhaps I'll try this idea, as well.  Making this work would depend on the order of the hair polygons/lines.  I'll have to see how the ordering of these works out.  It's possible that a symmetrical parent object which isn't mirrored might have its own vertices in an order which would generate incompatible hair props with different polygon orders....

===========================sigline======================================================

Cage can be an opinionated jerk who posts without thinking.  He apologizes for this.  He's honestly not trying to be a turkeyhead.

Cage had some freebies, compatible with Poser 11 and below.  His Python scripts were saved at archive.org, along with the rest of the Morphography site, where they were hosted.