Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksi Juvani <aleksijuvani>2022-01-07 19:45:06 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2022-01-18 11:42:27 +0300
commit6570d5596becafa0b3245deefdb326f0ff1e4f54 (patch)
treea360b329f1e4ca46b2b702d8a21c0bc0dec24d97
parenta4171f48661b87b4a2e4ca66f1156c863261d759 (diff)
Fix: connecting hair fails on meshes with no generative modifiers
Fixes a bug introduced in rB5dedb39d447b. `mesh_original` is not set if the mesh has no generative modifiers, in which case we can use `mesh_final`, which would seem to be consistent with the rest of the particle code. An alternative approach would be to make sure that `mesh_original` is always set in `deformVerts`. Differential Revision: https://developer.blender.org/D13754
-rw-r--r--source/blender/editors/physics/particle_object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/physics/particle_object.c b/source/blender/editors/physics/particle_object.c
index 794b59b4c8a..141315d5200 100644
--- a/source/blender/editors/physics/particle_object.c
+++ b/source/blender/editors/physics/particle_object.c
@@ -745,7 +745,7 @@ static bool remap_hair_emitter(Depsgraph *depsgraph,
const bool use_dm_final_indices = (target_psys->part->use_modifier_stack &&
!target_psmd->mesh_final->runtime.deformed_only);
- if (use_dm_final_indices) {
+ if (use_dm_final_indices || !target_psmd->mesh_original) {
mesh = target_psmd->mesh_final;
}
else {