diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2018-05-18 18:31:59 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2018-05-22 18:08:57 +0300 |
commit | e89fa4c85b8e249465158215ade49e3726a0e7a0 (patch) | |
tree | 93d3ff0c2dc7e967e113fa6729d9295b90a00e9f /source/blender/blenkernel/intern/cloth.c | |
parent | 6953c57d2c9317f46387b3a80c1b68108c2c0dfa (diff) |
Cloth Modifier: get time from depsgraph instead of scene
Diffstat (limited to 'source/blender/blenkernel/intern/cloth.c')
-rw-r--r-- | source/blender/blenkernel/intern/cloth.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/cloth.c b/source/blender/blenkernel/intern/cloth.c index 976b8965fa2..d769020503b 100644 --- a/source/blender/blenkernel/intern/cloth.c +++ b/source/blender/blenkernel/intern/cloth.c @@ -41,6 +41,7 @@ #include "BLI_linklist.h" #include "DEG_depsgraph.h" +#include "DEG_depsgraph_query.h" #include "BKE_cdderivedmesh.h" #include "BKE_cloth.h" @@ -411,7 +412,7 @@ void clothModifier_do(ClothModifierData *clmd, struct Depsgraph *depsgraph, Scen int cache_result; clmd->scene= scene; /* nice to pass on later :) */ - framenr= (int)scene->r.cfra; + framenr = DEG_get_ctime(depsgraph); cache= clmd->point_cache; BKE_ptcache_id_from_cloth(&pid, ob, clmd); |