diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2018-05-24 17:40:08 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2018-05-24 17:43:21 +0300 |
commit | e8c8ff4f86c276e4dca884ff1a411fcbbf003fed (patch) | |
tree | 484745e65e0eb2559c62be0a7581c3102d8cb84b /source/blender/modifiers/intern/MOD_boolean.c | |
parent | 10e43c0aef38647d8904e758e36261c9ac0b6460 (diff) |
Fix all modifiers that depended on BKE_modifier_get_evaluated_mesh_from_object
This fix applying the following modifiers:
* Boolean (working already)
* Array
* Mesh Deform
* Surface Deform
* Vertex Weight Proximity
This function was to return evaluated mesh. So it should get the evaluated
object at all times. So in this case it makes more sense to simply pass the
depsgraph (or in this case the ModifierEvalContext that contains both the
depsgraph and the flag.
Solution discussed with Bastien Montagne.
Diffstat (limited to 'source/blender/modifiers/intern/MOD_boolean.c')
-rw-r--r-- | source/blender/modifiers/intern/MOD_boolean.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/modifiers/intern/MOD_boolean.c b/source/blender/modifiers/intern/MOD_boolean.c index 29c322ae469..73d1388d88f 100644 --- a/source/blender/modifiers/intern/MOD_boolean.c +++ b/source/blender/modifiers/intern/MOD_boolean.c @@ -175,12 +175,11 @@ static Mesh *applyModifier(ModifierData *md, const ModifierEvalContext *ctx, Mes if (!bmd->object) return mesh; - Object *other_eval = DEG_get_evaluated_object(ctx->depsgraph, bmd->object); - mesh_other = BKE_modifier_get_evaluated_mesh_from_object(other_eval, ctx->flag); - + mesh_other = BKE_modifier_get_evaluated_mesh_from_object(ctx, bmd->object); if (mesh_other) { Mesh *result; Object *object_eval = DEG_get_evaluated_object(ctx->depsgraph, ctx->object); + Object *other_eval = DEG_get_evaluated_object(ctx->depsgraph, bmd->object); /* when one of objects is empty (has got no faces) we could speed up * calculation a bit returning one of objects' derived meshes (or empty one) |