[Bf-blender-cvs] [efd1414] hair_immediate_fixes: Use identity transform in the solver data roots to avoid possible errors when this data is used outside the transform functions.

Lukas Tönne noreply at git.blender.org
Fri Sep 12 12:38:17 CEST 2014


Commit: efd1414d902f56046bbd873536c1c4ab4e325c49
Author: Lukas Tönne
Date:   Fri Sep 12 12:28:56 2014 +0200
Branches: hair_immediate_fixes
https://developer.blender.org/rBefd1414d902f56046bbd873536c1c4ab4e325c49

Use identity transform in the solver data roots to avoid possible errors
when this data is used outside the transform functions.

===================================================================

M	source/blender/blenkernel/intern/implicit.c

===================================================================

diff --git a/source/blender/blenkernel/intern/implicit.c b/source/blender/blenkernel/intern/implicit.c
index 46c20ff..33b5404 100644
--- a/source/blender/blenkernel/intern/implicit.c
+++ b/source/blender/blenkernel/intern/implicit.c
@@ -2838,8 +2838,14 @@ void implicit_set_positions(ClothModifierData *clmd)
 	Implicit_Data *id = cloth->implicit;
 	
 	for (i = 0; i < numverts; i++) {
+#ifdef CLOTH_ROOT_FRAME
 		copy_v3_v3(id->root[i].loc, cloth_roots[i].loc);
 		copy_m3_m3(id->root[i].rot, cloth_roots[i].rot);
+#else
+		zero_v3(id->root[i].loc);
+		unit_m3(id->root[i].rot);
+		(void)cloth_roots;
+#endif
 		
 		loc_world_to_root(id->X[i], verts[i].x, &id->root[i]);
 		vel_world_to_root(id->V[i], id->X[i], verts[i].v, &id->root[i]);




More information about the Bf-blender-cvs mailing list