A community member requested a how-to on the soft-body hair concept, so here’s some info:
My character will be in fairly extreme motion during the planned animation, and as designed, has “half a head” of longish hair. This presents the problem of getting the hair to move in a somewhat naturalistic manner during the character’s moves.
I’d already played with Blender’s soft-body physics briefly just to get an idea of its capabilities, and after deciding particle-based hair wasn’t going to cut it for me (or is that haircut it for me??? ), I came up with the idea of using soft-body physics to get the hair to move with the character.
Soft-body physics is probably most often thought of in terms of cloth-type simulations, and my hair approach actually builds on that. Imagine a “wig” made of fairly stiff cloth, with long strips hanging down from top to sides. Now shade it with an alpha-channel material that gives parts of it a wispy look and you have a fairly decent stylized hair effect (see vid link below). That’s the basic concept I’m developing (this is still a WIP, remember).
The “wig” modeling was pretty straightforward. I duped a patch from the top of the model’s head as a separate object to start with (Fig 1), then modeled “strand clumps” to hang like flat dreadlocks, plus some bangs. Only these portions of the hair would have any substantial movement. I plan to add some more geometry to give the effect more apparent volume after the basic effect is solid.
The wig was made a child of my character rig’s Skull01 bone, since it has to move with the head. The parenting plays a critical part in the soft-body hair system: Using weight painting, you can restrict the freedom of the soft-body mesh to act like a soft body, making it possible to “adhere” the “scalp-ends” of the hair to the head while letting the “strands” move freely. Weight-painting is the “glue” that holds the wig in place. In the pic, red is full weight (1.0) to hold the “cap” portion in place and transitions to dark blue (0.0) along the length of the hair strand strips. It’s OK to use the extremes of weight here – the soft-body settings allow you to tweak the min/max of the weighting without further painting.
One critical part of the weight-painting that doesn’t show clearly in the pic: I added a small amount of weight to the verts at the very tips of the hair strands (about 0.1 or less). This gives the tips a small amount of pseudo-inertia that helps keep the motion more naturalistic.
The soft-body settings were largely arrived at by trial and error, and may be useful only for this model setup. Very important parameters to set are those in the Goal section. These values determine how much of the s-b motion is governed by the wig’s attachment to the Skull01 bone (note that this bone is specified in this section), based on the weight painting values. A weight of 1.0 makes the mesh act like a normal mesh, with the Skull01 bone governing all motion. At weight 0.0, the mesh is completely free to act as a soft body. The trick of weight painting is finding the best distribution of weights, and the minimum and maximum needed, to get the strands moving in a close-to-hairlike fashion.
The other s-b settings govern the character of the hair-strand motion and should be seen only as starting points. Expect to do a lot of tweak and test on these values.
The other half of the soft-body equation involves collision, which Blender calls “Deflection”, because you don’t want the hair strands to intersect with the body mesh. Collision really slows the sim but is a critical factor, so cultivate patience while using it. The pic shows the Deflection settings I applied to the body mesh.
One requirement for Deflection to work that I don’t remember seeing in the wiki Manual is that the two meshes must be on the same layer. The soft-body motion will still work, but if the meshes reside on separate layers, the s-b mesh will intersect the body mesh regardless of Deflection settings. Another tip is that while soft-body physics is enabled, Sculpting Mode doesn’t work, so switch it off if you want to use Sculpting to modify the wig mesh.
Setting up the final specs for the s-b sim takes a fair amount of time because the physics calculations slow real-time playback (Timeline) quite dramatically. With experience you can get a feel for the true look of the effect by watching the playback crawl by and knowing how many frames are being used for the sequence, but to truly evalute the motion, a test-render is called for. Since you’re only interested in the motion characteristics, test runs can be made with all other time-consuming settings (subsurf, OSA and the like) turned off or way, way down, to speed up the test renders.
You’ll probably do some modifications to the wig mesh during testing, because successful Deflection is dependent on mesh density in addition to other factors. You can choose to detect collision between edges or faces or both, but using faces changes the effect pretty dramatically and takes more calculation time. This example uses only edges, and to make sure there are no intersections with the body, I had to restructure the wig mesh a few times. When optimizing the wig mesh, keep in mind more vertices means longer s-b math calculation times.
I’m currently working on the appearance of the hair system, which will eventually be a combination of procedural color, painted texture color, alpha and bump mapping. This vid shows the start of this process:
Soft-body hair with alpha applied (full render test)
I’m not sure that this approach to simulating hair in motion will hold up for very long sequences; that has yet to be tested. It also has a very stylized look that may not lend itself to every project. But it seems a workable solution for some situations.
Hope you found this helpful!