Page MenuHome

Hair particles: rekeying, cut tool, subdividing do not interpolate existing weights (breaking simulation)
Confirmed, NormalPublicKNOWN ISSUE

Description

System Information
Operating system: Windows-10-10.0.17134 64 Bits
Graphics card: GeForce GTX 1070/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 418.81

Blender Version
Broken: version: 2.80 (sub 51), branch: blender2.7, commit date: 2019-03-25 23:15, hash: rBadfdae3fc2f4
Worked: (optional)
Just click once sometimes work right

Short description of error
[Please fill out a short description of the error here]

This bug happen in both 2.79 and 2.8
Click and drag the hair cut tool mess up the vertices position, especially after subdividing one or 2 segments of the hair. After the hair is messed up, it can't be fixed using rekey command.
Dragging the cut tool on a hair that is not subdivided also cause the problem, but not as severely, the vertices become unevenly positioned.

Exact steps for others to reproduce the error
[Please describe the exact steps needed to reproduce the issue]
[Based on the default startup or an attached .blend file (as simple as possible)]

Create a hair system on the default cube, set the emission number to 1.
Go to particle edit mode, subdivide one or 2 segments of the hair.
Use the cut tool, click and drag from the tip of the hair.
The hair is now completely messed up.

Event Timeline

Jacques Lucke (JacquesLucke) lowered the priority of this task from 90 to 50.Mar 27 2019, 12:33 PM

Any update on this bug ?
The cut tool can make our lives so much easier, but it's not usable with the current state.

@Lance Phan (ssendam) wrote:

The hair is now completely messed up.

A few notes to somewhat resolve this broadly contoured observation.

Create a hair system on the default cube, set the emission number to 1.

Mine looks like this:


The single hair particle has three keys: one root, one midway key and one tip.
Here is a weight dump of those keys from the python console:

>>> solo = bpy.context.active_object.particle_systems['Solo']
>>> type(solo)
<class 'bpy.types.ParticleSystem'>
>>> for k in solo.particles[0].hair_keys : k.weight 
1.0
0.5
0.0
>>>

This is the visualization of the hair and its keys, using the weight paint tool while in Particle Edit mode. The root has a weight of one, the tip has a weight of zero and the midway key has a weight of one-half.


By the way, the host mesh is a one-face plane. We're peering down the Y+ axis toward the origin, Orthographic projection.
For readers new to the Blender Hair Party, hair key weights engender immobility under Hair Dynamics. Under the root, weight 1.0, is frozen in place. The tip, weight 0.0, is freely affected by gravity and such. The midway key is half-immobile at 0.5.

Go to particle edit mode, subdivide one or 2 segments of the hair.

I'll subdivide the segment between the midway key (weight 0.5: 'green') and the root key (weight 1.0: 'red')


We are in the weeds. Select two keys and subdivide from the right-hand mouse button menu invokes bpy.ops.particle.subdivide() which places a new key nicely between the two selected keys - but weights it at zero.

>>> for k in solo.particles[0].hair_keys: k.weight
... 
1.0
0.0
0.5
0.0

>>>

This leads to non uniform hair dynamics - nice, if that is what is wanted, but, for users unaware of no-longer-evenly descending weights on the keys, it is, I suspect, the first step down the road to having completely messed up hair: Under gravity, the keys will fall at non-ascending rates. Short discussion: the hair will hang funny. This appears to be T67301 rearing its head.

Use the cut tool, click and drag from the tip of the hair.

Emphasis mine. Click (and no drag) evenly spaces the keys along the surviving length. Note that Blender preserves the key count: it does not remove keys during cuts. Click and drag, however, makes the interior keys - those between the tip and root - dance randomly.


On button release, the intervals between keys vary randomly. Short discussion: the hair will hang even more funnily.

The hair is now completely messed up.

Indeed.
Hopefully, these notes will be helpful to the occasional particle repairmen who happen by, now and again.
[Edit]
Neglected to upload the test file.

Philipp Oeser (lichtwerk) renamed this task from hair cut tool severely mess up the hair to Hair particles: rekeying, cut tool, subdividing do not interpolate existing weights (breaking simulation).Nov 20 2019, 12:42 PM
Philipp Oeser (lichtwerk) changed the subtype of this task from "Report" to "Known Issue".

Hopefully, we can sneak this improvement in when doing the work on T68981: New hair object type.
For now, this will be tagged as Known Issue...

Stepping down due to time constraints and to not block this task.
It seems more reasonable to work on T68981 instead.