[Bf-blender-cvs] [320771dc741] cloth-improvements: Copy cache when copying cloth object
Luca Rood
noreply at git.blender.org
Tue Apr 4 11:57:12 CEST 2017
Commit: 320771dc741b366bbb35abae46bdd2166722f2b6
Author: Luca Rood
Date: Tue Apr 4 11:56:25 2017 +0200
Branches: cloth-improvements
https://developer.blender.org/rB320771dc741b366bbb35abae46bdd2166722f2b6
Copy cache when copying cloth object
===================================================================
M source/blender/modifiers/intern/MOD_cloth.c
===================================================================
diff --git a/source/blender/modifiers/intern/MOD_cloth.c b/source/blender/modifiers/intern/MOD_cloth.c
index 9e04d9dbc09..dd7db18b99f 100644
--- a/source/blender/modifiers/intern/MOD_cloth.c
+++ b/source/blender/modifiers/intern/MOD_cloth.c
@@ -198,8 +198,7 @@ static void copyData(ModifierData *md, ModifierData *target)
if (clmd->sim_parms->effector_weights)
tclmd->sim_parms->effector_weights = MEM_dupallocN(clmd->sim_parms->effector_weights);
tclmd->coll_parms = MEM_dupallocN(clmd->coll_parms);
- tclmd->point_cache = BKE_ptcache_add(&tclmd->ptcaches);
- tclmd->point_cache->step = 1;
+ tclmd->point_cache = BKE_ptcache_copy_list(&tclmd->ptcaches, &clmd->ptcaches, true);
tclmd->clothObject = NULL;
tclmd->hairdata = NULL;
tclmd->solver_result = NULL;
More information about the Bf-blender-cvs
mailing list