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:
authorLukas Tönne <lukas.toenne@gmail.com>2014-09-22 21:27:41 +0400
committerLukas Tönne <lukas.toenne@gmail.com>2015-01-20 11:30:02 +0300
commitc036c72284ea1e0447181274a65d1556d7c4a0d9 (patch)
treee78c8528db3807272bb06803cfe186c65cb058f4 /source/blender/blenkernel/BKE_cloth.h
parent3a8ef0ef6cd152bde5fb645e89df8131624da600 (diff)
Proper implementation of angular bending springs including jacobian
derivatives for stabilization. The bending forces are based on a simplified torsion model where each neighboring point of a vertex creates a force toward a local goal. This can be extended later by defining the goals in a local curve frame, so that natural hair shapes other than perfectly straight hair are supported. Calculating the jacobians for the bending forces analytically proved quite difficult and doesn't work yet, so the fallback method for now is a straightforward finite difference method. This works very well and is not too costly. Even the original paper ("Artistic Simulation of Curly Hair") suggests this approach.
Diffstat (limited to 'source/blender/blenkernel/BKE_cloth.h')
-rw-r--r--source/blender/blenkernel/BKE_cloth.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/blenkernel/BKE_cloth.h b/source/blender/blenkernel/BKE_cloth.h
index b7be7c60af5..acda9e11265 100644
--- a/source/blender/blenkernel/BKE_cloth.h
+++ b/source/blender/blenkernel/BKE_cloth.h
@@ -134,7 +134,10 @@ typedef struct ClothSpring {
int kl; /* Pkl from the paper, one end of the spring. */
int mn;
float restlen; /* The original length of the spring. */
- int matrix_index; /* needed for implicit solver (fast lookup) */
+ /* needed for implicit solver (fast lookup) */
+ int matrix_ij_kl;
+ int matrix_kl_mn;
+ int matrix_ij_mn;
int type; /* types defined in BKE_cloth.h ("springType") */
int flags; /* defined in BKE_cloth.h, e.g. deactivated due to tearing */
float dfdx[3][3];