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:
authorSergey Sharybin <sergey.vfx@gmail.com>2018-02-15 13:22:44 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2018-02-15 14:24:48 +0300
commit6d4022f61980ba46efd391dcfe96dd88a8db8deb (patch)
tree47de0c472537be5d8eb8550135c3c3e039d5a594 /source/blender/makesdna
parent5ce6ca05366e653cc576ac6beaed72d07c0e2e6c (diff)
Simple hair children: Make twist affected by texture
This completes twist feature, which is now possible to also control by texture. Since textures can not easily contain negative values as well, same trick with 0.5 neutral as vertex groups is used. All in all, this twist features allows to do following things. Original hair: {F2287535} Hair with scientifically calculated twist value of 0.5: {F2287540} And we can also twist braids in opposite directions dependent on left/right side: {F2287548}
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_particle_types.h3
-rw-r--r--source/blender/makesdna/DNA_texture_types.h2
2 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/makesdna/DNA_particle_types.h b/source/blender/makesdna/DNA_particle_types.h
index 8dd4d46a596..9dbd1a18703 100644
--- a/source/blender/makesdna/DNA_particle_types.h
+++ b/source/blender/makesdna/DNA_particle_types.h
@@ -614,7 +614,8 @@ typedef enum eParticleTextureInfluence {
PAMAP_KINK_AMP = (1<<12),
PAMAP_ROUGH = (1<<9),
PAMAP_LENGTH = (1<<4),
- PAMAP_CHILD = (PAMAP_CLUMP | PAMAP_KINK_FREQ | PAMAP_KINK_AMP | PAMAP_ROUGH | PAMAP_LENGTH),
+ PAMAP_TWIST = (1<<13),
+ PAMAP_CHILD = (PAMAP_CLUMP | PAMAP_KINK_FREQ | PAMAP_KINK_AMP | PAMAP_ROUGH | PAMAP_LENGTH | PAMAP_TWIST),
} eParticleTextureInfluence;
#endif
diff --git a/source/blender/makesdna/DNA_texture_types.h b/source/blender/makesdna/DNA_texture_types.h
index 995d7645dc0..0eb54a9b5b3 100644
--- a/source/blender/makesdna/DNA_texture_types.h
+++ b/source/blender/makesdna/DNA_texture_types.h
@@ -86,7 +86,7 @@ typedef struct MTex {
float timefac, lengthfac, clumpfac, dampfac;
float kinkfac, kinkampfac, roughfac, padensfac, gravityfac;
float lifefac, sizefac, ivelfac, fieldfac;
- int pad2;
+ float twistfac;
/* lamp */
float shadowfac;