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:
authorBastien Montagne <montagne29@wanadoo.fr>2019-04-29 10:34:20 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2019-04-29 11:08:16 +0300
commit383fef9f10481d1dd5b8bf92a33b8d0995b136d4 (patch)
treeb9f2970854e222a03bf77ccacfb1a407b5687747
parentf54192e09aade8614f1812944ba9f3faea0086bf (diff)
Fix T63616: applying armature modifier with another modifier under it doesnt apply right.
Some deform modifiers (like armature) use passed Mesh parameter to retrieve some extra data (vgroups in our case), and default to obdata when it is not available. This should be fine in theory in the 'apply modifier to obdata' case, since this is always the first modifier, but here upper-level code passes **evaluated** object, not orig one, so ob->data is not orig anymore, and might miss some stuff... Note that am quiet unsure whether the way evaluated data is passed around in that apply modifier operator code is actually OK, but for now it seems to work at least...
-rw-r--r--source/blender/blenkernel/intern/mesh_convert.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/mesh_convert.c b/source/blender/blenkernel/intern/mesh_convert.c
index 0402524e03d..3f4e504867c 100644
--- a/source/blender/blenkernel/intern/mesh_convert.c
+++ b/source/blender/blenkernel/intern/mesh_convert.c
@@ -1265,8 +1265,8 @@ Mesh *BKE_mesh_create_derived_for_modifier(struct Depsgraph *depsgraph,
int numVerts;
float(*deformedVerts)[3] = BKE_mesh_vertexCos_get(me, &numVerts);
- mti->deformVerts(md_eval, &mectx, NULL, deformedVerts, numVerts);
BKE_id_copy_ex(NULL, &me->id, (ID **)&result, LIB_ID_COPY_LOCALIZE);
+ mti->deformVerts(md_eval, &mectx, result, deformedVerts, numVerts);
BKE_mesh_apply_vert_coords(result, deformedVerts);
if (build_shapekey_layers) {