2
$\begingroup$

Issue

When I rotate the head bone, all the bones for the hair follows the head movement and clips through the body mesh like this image without any collision. How do I create collision detection for mesh hair with bones? Are there otherwise ways to "lock" certain hair bones from moving when rotating the head to avoid any mesh hair clipping through the body?

$\endgroup$

1 Answer 1

3
$\begingroup$

I don't think collision detection for bones is possible. There are bone constraints but they are for planes like a wall or floor, see Floor Constraint.

As suggested by moonboots in the comments here (How Do I Add Collision For Armature) you can use Blender's physics to have collision detection. That's Cloth and Softbody simulations.

You need to

  • add low-poly planes or cages that will do the deform
  • make them a Cloth or a Softbody
  • bind the hair mesh with a Surface Deform (or a Mesh Deform) modifier to the planes/cages
  • you can define a vertex group in the Surface Deform settings to control which part of the hair mesh is deformed.
  • parent the hair to the deform planes, and the planes to the head (or armature). If you have only one hair mesh it's ok to parent it to one of the planes/cages.

Example:

animated cloth hair

  • 1 hair mesh with 2 strands (modeled with curves).
  • 2 planes with a cloth system each. The first uses the cloth Rubber preset, the other the stiffer Leather preset. Each root of the deform planes is in a "Pin" group to pin the hair. It's used for Cloth settings > Shape > Pin Group
  • the hair strand has 2 Surface Deform modifiers that bind it to the deform planes. A vertex group for each strand defines which parts/strands are affected by the modifier.
  • the head, and both planes have Collision enabled

screenshot

$\endgroup$
1
  • $\begingroup$ +1 great answer $\endgroup$
    – Chris
    Commented Oct 12, 2021 at 8:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .