Merge branch 'master' into blender2.8
[blender.git] / source / blender / modifiers / intern / MOD_correctivesmooth.c
index f05902641141823414ffdd02f7e38fccf19cdbe1..aae58f4bbafb7a76413cba157d9b11d0ac54cef5 100644 (file)
@@ -713,12 +713,12 @@ error:
 
 
 static void deformVerts(
-        ModifierData *md, Object *ob, DerivedMesh *derivedData,
-        float (*vertexCos)[3], int numVerts, ModifierApplyFlag UNUSED(flag))
+        ModifierData *md, const ModifierEvalContext *ctx, DerivedMesh *derivedData,
+        float (*vertexCos)[3], int numVerts)
 {
-       DerivedMesh *dm = get_dm(ob, NULL, derivedData, NULL, false, false);
+       DerivedMesh *dm = get_dm(ctx->object, NULL, derivedData, NULL, false, false);
 
-       correctivesmooth_modifier_do(md, ob, dm, vertexCos, (unsigned int)numVerts, NULL);
+       correctivesmooth_modifier_do(md, ctx->object, dm, vertexCos, (unsigned int)numVerts, NULL);
 
        if (dm != derivedData) {
                dm->release(dm);
@@ -727,12 +727,12 @@ static void deformVerts(
 
 
 static void deformVertsEM(
-        ModifierData *md, Object *ob, struct BMEditMesh *editData,
+        ModifierData *md, const ModifierEvalContext *ctx, struct BMEditMesh *editData,
         DerivedMesh *derivedData, float (*vertexCos)[3], int numVerts)
 {
-       DerivedMesh *dm = get_dm(ob, editData, derivedData, NULL, false, false);
+       DerivedMesh *dm = get_dm(ctx->object, editData, derivedData, NULL, false, false);
 
-       correctivesmooth_modifier_do(md, ob, dm, vertexCos, (unsigned int)numVerts, editData);
+       correctivesmooth_modifier_do(md, ctx->object, dm, vertexCos, (unsigned int)numVerts, editData);
 
        if (dm != derivedData) {
                dm->release(dm);
@@ -749,17 +749,25 @@ ModifierTypeInfo modifierType_CorrectiveSmooth = {
                                eModifierTypeFlag_SupportsEditmode,
 
        /* copyData */          copyData,
-       /* deformVerts */       deformVerts,
+
+       /* deformVerts_DM */    deformVerts,
+       /* deformMatrices_DM */ NULL,
+       /* deformVertsEM_DM */  deformVertsEM,
+       /* deformMatricesEM_DM*/NULL,
+       /* applyModifier_DM */  NULL,
+       /* applyModifierEM_DM */NULL,
+
+       /* deformVerts */       NULL,
        /* deformMatrices */    NULL,
-       /* deformVertsEM */     deformVertsEM,
+       /* deformVertsEM */     NULL,
        /* deformMatricesEM */  NULL,
        /* applyModifier */     NULL,
        /* applyModifierEM */   NULL,
+
        /* initData */          initData,
        /* requiredDataMask */  requiredDataMask,
        /* freeData */          freeData,
        /* isDisabled */        NULL,
-       /* updateDepgraph */    NULL,
        /* updateDepsgraph */   NULL,
        /* dependsOnTime */     NULL,
        /* dependsOnNormals */  NULL,