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:
authorDaniel Genrich <daniel.genrich@gmx.net>2008-04-09 20:38:26 +0400
committerDaniel Genrich <daniel.genrich@gmx.net>2008-04-09 20:38:26 +0400
commit906666a4d87b7812e0945acb5803be3ca43fcdbb (patch)
tree706cbe78eebbb004990ea6f32956de55bf608794 /source/blender/blenkernel/intern/implicit.c
parent235f793f28bebf1fdfbc94bf8fc2f0c3ac727c49 (diff)
Cloth enhancement for upcomming cache changes: support different speed using clmd->sim_parms->timescale
Diffstat (limited to 'source/blender/blenkernel/intern/implicit.c')
-rw-r--r--source/blender/blenkernel/intern/implicit.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/implicit.c b/source/blender/blenkernel/intern/implicit.c
index 4c39f36800c..639ce188235 100644
--- a/source/blender/blenkernel/intern/implicit.c
+++ b/source/blender/blenkernel/intern/implicit.c
@@ -1387,7 +1387,9 @@ void cloth_calc_force(ClothModifierData *clmd, lfVector *lF, lfVector *lX, lfVec
init_lfvector(lF, gravity, numverts);
- // multiply lF with mass matrix
+ /* multiply lF with mass matrix
+ // force = mass * acceleration (in this case: gravity)
+ */
for(i = 0; i < (long)numverts; i++)
{
float temp[3];
@@ -1528,7 +1530,7 @@ int implicit_solver (Object *ob, float frame, ClothModifierData *clmd, ListBase
Cloth *cloth = clmd->clothObject;
ClothVertex *verts = cloth->verts;
unsigned int numverts = cloth->numverts;
- float dt = 1.0f / clmd->sim_parms->stepsPerFrame;
+ float dt = clmd->sim_parms->timescale / clmd->sim_parms->stepsPerFrame;
Implicit_Data *id = cloth->implicit;
int result = 0;