[Bf-blender-cvs] [396f7ea] master: Don't try to enforce a velocity change for pinned vertices; their velocity is defined externally by hair root motion.
Lukas Tönne
noreply at git.blender.org
Tue Jan 20 09:49:47 CET 2015
Commit: 396f7ea1582b89fa33af4b4ff0a5562534316f7b
Author: Lukas Tönne
Date: Thu Sep 4 19:58:17 2014 +0200
Branches: master
https://developer.blender.org/rB396f7ea1582b89fa33af4b4ff0a5562534316f7b
Don't try to enforce a velocity change for pinned vertices; their
velocity is defined externally by hair root motion.
===================================================================
M source/blender/blenkernel/intern/implicit.c
===================================================================
diff --git a/source/blender/blenkernel/intern/implicit.c b/source/blender/blenkernel/intern/implicit.c
index 0d4a7ec..227bd2a 100644
--- a/source/blender/blenkernel/intern/implicit.c
+++ b/source/blender/blenkernel/intern/implicit.c
@@ -1768,18 +1768,15 @@ static void setup_constraint_matrix(ClothModifierData *clmd, ColliderContacts *c
int numverts = clmd->clothObject->numverts;
int i, j, v;
- /* Clear matrix from old vertex constraints */
- for (v = 0; v < S[0].vcount; v++)
- S[v].c = S[v].r = 0;
-
- /* pinned vertex constraints */
for (v = 0; v < numverts; v++) {
S[v].c = S[v].r = v;
if (verts[v].flags & CLOTH_VERT_FLAG_PINNED) {
- negate_v3_v3(z[v], verts[v].v);
+ /* pinned vertex constraints */
+ zero_v3(z[v]); /* velocity is defined externally */
zero_m3(S[v].m);
}
else {
+ /* free vertex */
zero_v3(z[v]);
unit_m3(S[v].m);
}
More information about the Bf-blender-cvs
mailing list