diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-06-22 16:03:42 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-06-22 16:12:03 +0300 |
commit | a7ca8fe1dd111f0b99c1b17cdd6b0f7e1c6f987b (patch) | |
tree | 98d27b8d18a21c6389f3090b0f8d92c6b5f595e0 /source/blender/modifiers/intern/MOD_cloth.c | |
parent | 7a4b784909b3d31f318f92ddcfd534223f3e8412 (diff) |
Modifiers: Remove lots of usages of md->scene
Diffstat (limited to 'source/blender/modifiers/intern/MOD_cloth.c')
-rw-r--r-- | source/blender/modifiers/intern/MOD_cloth.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/modifiers/intern/MOD_cloth.c b/source/blender/modifiers/intern/MOD_cloth.c index 19afe30acae..05c9e44d980 100644 --- a/source/blender/modifiers/intern/MOD_cloth.c +++ b/source/blender/modifiers/intern/MOD_cloth.c @@ -54,6 +54,8 @@ #include "BKE_modifier.h" #include "BKE_pointcache.h" +#include "DEG_depsgraph_query.h" + #include "MOD_util.h" static void initData(ModifierData *md) @@ -78,6 +80,7 @@ static void deformVerts( { Mesh *mesh_src; ClothModifierData *clmd = (ClothModifierData *) md; + Scene *scene = DEG_get_evaluated_scene(ctx->depsgraph); /* check for alloc failing */ if (!clmd->sim_parms || !clmd->coll_parms) { @@ -123,7 +126,7 @@ static void deformVerts( BKE_mesh_apply_vert_coords(mesh_src, vertexCos); - clothModifier_do(clmd, ctx->depsgraph, md->scene, ctx->object, mesh_src, vertexCos); + clothModifier_do(clmd, ctx->depsgraph, scene, ctx->object, mesh_src, vertexCos); BKE_id_free(NULL, mesh_src); } |