Page MenuHome

Fix T54488: hair disconnect/reconnect not working with modifiers
ClosedPublic

Authored by Aleksi Juvani (aleksijuvani) on Jan 1 2022, 6:38 PM.

Diff Detail

Repository
rB Blender

Event Timeline

Brecht Van Lommel (brecht) requested changes to this revision.Jan 5 2022, 3:23 PM

Thanks for the patch!

source/blender/editors/physics/particle_object.c
746–749

It seems that this also changes the logic when use_modifier_stack is false.

Is that intentional and if so, can you explain why it was done?

This revision now requires changes to proceed.Jan 5 2022, 3:23 PM
source/blender/editors/physics/particle_object.c
746–749

I've changed the logic here to match the logic for attaching hairs in PE_mirror_x and brush_add_count_iter. It's unclear to me what the original intention was here, but based off of those two functions, my suspicion was that it's a mistake, that is, the check should've originally been for !target_psmd->mesh_final->runtime.deformed_only instead of target_psmd->mesh_final->runtime.deformed_only. I can investigate this further, but for the purposes of this patch, it's not strictly necessary to change the behaviour when use_modifier_stack is false.

It indeed seems this also improves things when using deforming modifiers (like armature), so the old code was wrong for that case.

This revision is now accepted and ready to land.Jan 5 2022, 4:53 PM