diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-05-30 17:18:08 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-05-30 18:00:47 +0300 |
commit | 25d4d43491055c4c7c0a523a0ddb0bf027d1515d (patch) | |
tree | 85aaf573d50fc8bf6fb73e155e2c8baa4f86f0e3 /source/blender/modifiers/intern | |
parent | cdfa5177608d6f78338477b293beb3e92b7335ed (diff) |
Modifiers: Restore duplication of referenced layers
Was no reason to remove those calls, it was always a plan to bring
referenced layers back eventually.
Diffstat (limited to 'source/blender/modifiers/intern')
4 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/modifiers/intern/MOD_normal_edit.c b/source/blender/modifiers/intern/MOD_normal_edit.c index 67d20e1a52f..5ac6569ea1f 100644 --- a/source/blender/modifiers/intern/MOD_normal_edit.c +++ b/source/blender/modifiers/intern/MOD_normal_edit.c @@ -450,7 +450,7 @@ static Mesh *normalEditModifier_do(NormalEditModifierData *enmd, Object *ob, Mes result->runtime.cd_dirty_vert &= ~CD_MASK_NORMAL; if (use_current_clnors) { - clnors = CustomData_get_layer(ldata, CD_CUSTOMLOOPNORMAL); + clnors = CustomData_duplicate_referenced_layer(ldata, CD_CUSTOMLOOPNORMAL, num_loops); BKE_mesh_normals_loop_split(mvert, num_verts, medge, num_edges, mloop, loopnors, num_loops, mpoly, (const float (*)[3])polynors, num_polys, diff --git a/source/blender/modifiers/intern/MOD_weightvgedit.c b/source/blender/modifiers/intern/MOD_weightvgedit.c index 7c71dd5159e..18d79966938 100644 --- a/source/blender/modifiers/intern/MOD_weightvgedit.c +++ b/source/blender/modifiers/intern/MOD_weightvgedit.c @@ -212,7 +212,7 @@ static Mesh *applyModifier( false); if (has_mdef) { - dvert = CustomData_get_layer(&result->vdata, CD_MDEFORMVERT); + dvert = CustomData_duplicate_referenced_layer(&result->vdata, CD_MDEFORMVERT, numVerts); } else { /* Add a valid data layer! */ diff --git a/source/blender/modifiers/intern/MOD_weightvgmix.c b/source/blender/modifiers/intern/MOD_weightvgmix.c index 1736bb01951..eeaf292991f 100644 --- a/source/blender/modifiers/intern/MOD_weightvgmix.c +++ b/source/blender/modifiers/intern/MOD_weightvgmix.c @@ -253,7 +253,7 @@ static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mes false); if (has_mdef) { - dvert = CustomData_get_layer(&result->vdata, CD_MDEFORMVERT); + dvert = CustomData_duplicate_referenced_layer(&result->vdata, CD_MDEFORMVERT, numVerts); } else { /* Add a valid data layer! */ diff --git a/source/blender/modifiers/intern/MOD_weightvgproximity.c b/source/blender/modifiers/intern/MOD_weightvgproximity.c index 4549e60a8d8..52d94cfd76c 100644 --- a/source/blender/modifiers/intern/MOD_weightvgproximity.c +++ b/source/blender/modifiers/intern/MOD_weightvgproximity.c @@ -431,7 +431,7 @@ static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mes false); if (has_mdef) { - dvert = CustomData_get_layer(&result->vdata, CD_MDEFORMVERT); + dvert = CustomData_duplicate_referenced_layer(&result->vdata, CD_MDEFORMVERT, numVerts); } else { /* Add a valid data layer! */ |