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:
authorJacques Lucke <mail@jlucke.com>2018-09-20 13:04:17 +0300
committerJacques Lucke <mail@jlucke.com>2018-09-20 13:04:17 +0300
commitb5dbe43d3ebfdc238d56bbb71ec17735cebdc951 (patch)
tree09e09ea4d5d78887e048b214f7ca9a0011641e5d /source/blender/modifiers/intern/MOD_dynamicpaint.c
parentadd8e1c018bb5342cdad14a7d143d2b38ffa5bf5 (diff)
Cleanup: move DerivedMesh wrappers for modifiers further down the hierarchy
The main goal of this patch is to cleanup the interface of every modifier. More specifically the interface of modifiers should be DerivedMesh-free. Internally some modifiers still use DerivedMesh. However I think it is better when the wrappers are in the modifiers so that higher level functions can use the simplified interface. This patch removes the applyModifier_DM and applyModifierEM_DM functions. In a previous patch (rB3614d9d) the other functions that used DerivedMesh have been removed. Reviewers: brecht
Diffstat (limited to 'source/blender/modifiers/intern/MOD_dynamicpaint.c')
-rw-r--r--source/blender/modifiers/intern/MOD_dynamicpaint.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/modifiers/intern/MOD_dynamicpaint.c b/source/blender/modifiers/intern/MOD_dynamicpaint.c
index 61219096b43..74dbb28d186 100644
--- a/source/blender/modifiers/intern/MOD_dynamicpaint.c
+++ b/source/blender/modifiers/intern/MOD_dynamicpaint.c
@@ -31,6 +31,7 @@
#include "DNA_object_types.h"
#include "DNA_object_force_types.h"
#include "DNA_scene_types.h"
+#include "DNA_mesh_types.h"
#include "BLI_utildefines.h"
@@ -100,7 +101,7 @@ static CustomDataMask requiredDataMask(Object *UNUSED(ob), ModifierData *md)
return dataMask;
}
-static DerivedMesh *applyModifier(
+static DerivedMesh *applyModifier_DM(
ModifierData *md, const ModifierEvalContext *ctx,
DerivedMesh *dm)
{
@@ -114,6 +115,8 @@ static DerivedMesh *applyModifier(
return dm;
}
+applyModifier_DM_wrapper(applyModifier, applyModifier_DM)
+
static bool is_brush_cb(Object *UNUSED(ob), ModifierData *pmd)
{
return ((DynamicPaintModifierData *)pmd)->brush != NULL;
@@ -183,14 +186,14 @@ ModifierTypeInfo modifierType_DynamicPaint = {
/* deformMatrices_DM */ NULL,
/* deformVertsEM_DM */ NULL,
/* deformMatricesEM_DM*/NULL,
- /* applyModifier_DM */ applyModifier,
+ /* applyModifier_DM */ NULL,
/* applyModifierEM_DM */NULL,
/* deformVerts */ NULL,
/* deformMatrices */ NULL,
/* deformVertsEM */ NULL,
/* deformMatricesEM */ NULL,
- /* applyModifier */ NULL,
+ /* applyModifier */ applyModifier,
/* applyModifierEM */ NULL,
/* initData */ initData,