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:
Diffstat (limited to 'source/blender/makesdna/DNA_particle_types.h')
-rw-r--r--source/blender/makesdna/DNA_particle_types.h68
1 files changed, 45 insertions, 23 deletions
diff --git a/source/blender/makesdna/DNA_particle_types.h b/source/blender/makesdna/DNA_particle_types.h
index 95cb5c84bed..07e944c360a 100644
--- a/source/blender/makesdna/DNA_particle_types.h
+++ b/source/blender/makesdna/DNA_particle_types.h
@@ -75,6 +75,7 @@ typedef struct ChildParticle {
float w[4]; /* interpolation weights for the above particles */
float fuv[4], foffset; /* face vertex weights and offset */
float rt;
+ int hull_parent; /* parent index of hull children, -1 if child is not part of the convex hull */
} ChildParticle;
typedef struct ParticleTarget {
@@ -123,6 +124,9 @@ typedef struct ParticleData {
int hair_index;
short flag;
short alive; /* the life state of a particle */
+
+ int blend_index[4]; /* particle indices for non-simulated hair */
+ float blend_weight[4]; /* blending weights for non-simulated hair */
} ParticleData;
typedef struct SPHFluidSettings {
@@ -240,6 +244,7 @@ typedef struct ParticleSettings {
struct CurveMapping *clumpcurve;
struct CurveMapping *roughcurve;
float clump_noise_size;
+ float clump_noise_random, clump_noise_random_size;
/* hair dynamics */
float bending_random;
@@ -268,12 +273,16 @@ typedef struct ParticleSystem {
struct ParticleSystem *next, *prev;
ParticleSettings *part; /* particle settings */
+ struct Key *key; /* hair goal shape keys */
+ short shapenr; /* current shape key for menu or pinned */
+ short pad[3];
ParticleData *particles; /* (parent) particles */
ChildParticle *child; /* child particles */
struct PTCacheEdit *edit; /* particle editmode (runtime) */
void (*free_edit)(struct PTCacheEdit *edit); /* free callback */
+ struct BMEditStrands *hairedit; /* hair edit data (runtime) */
struct ParticleCacheKey **pathcache; /* path cache (runtime) */
struct ParticleCacheKey **childcache; /* child cache (runtime) */
@@ -297,6 +306,8 @@ typedef struct ParticleSystem {
int seed, child_seed;
int flag, totpart, totunexist, totchild, totcached, totchildcache;
short recalc, target_psys, totkeyed, bakespace;
+ float hair_preview_factor; /* ratio of simulated to overall hairs */
+ int hair_num_simulated; /* current number of hairs tagged for simulation (for update check) */
char bb_uvname[3][64]; /* billboard uv name, MAX_CUSTOMDATA_LAYER_NAME */
@@ -321,7 +332,7 @@ typedef struct ParticleSystem {
struct ParticleDrawData *pdd;
float dt_frac; /* current time step, as a fraction of a frame */
- float _pad; /* spare capacity */
+ float pad2;
} ParticleSystem;
typedef enum eParticleDrawFlag {
@@ -436,11 +447,14 @@ typedef enum eParticleChildFlag {
} eParticleChildFlag;
/* part->draw_col */
-#define PART_DRAW_COL_NONE 0
-#define PART_DRAW_COL_MAT 1
-#define PART_DRAW_COL_VEL 2
-#define PART_DRAW_COL_ACC 3
-
+typedef enum eParticleDrawColorMode {
+ PART_DRAW_COL_NONE = 0,
+ PART_DRAW_COL_MAT = 1,
+ PART_DRAW_COL_VEL = 2,
+ PART_DRAW_COL_ACC = 3,
+ PART_DRAW_COL_PARENT = 4,
+ PART_DRAW_COL_TEX = 5,
+} eParticleDrawColorMode;
/* part->simplify_flag */
#define PART_SIMPLIFY_ENABLE 1
@@ -469,18 +483,21 @@ typedef enum eParticleChildFlag {
/* part->draw_as */
/* part->ren_as*/
-#define PART_DRAW_NOT 0
-#define PART_DRAW_DOT 1
-#define PART_DRAW_HALO 1
-#define PART_DRAW_CIRC 2
-#define PART_DRAW_CROSS 3
-#define PART_DRAW_AXIS 4
-#define PART_DRAW_LINE 5
-#define PART_DRAW_PATH 6
-#define PART_DRAW_OB 7
-#define PART_DRAW_GR 8
-#define PART_DRAW_BB 9
-#define PART_DRAW_REND 10
+typedef enum eParticleDrawMethod {
+ PART_DRAW_NOT = 0,
+ PART_DRAW_DOT = 1,
+ PART_DRAW_HALO = 1,
+ PART_DRAW_CIRC = 2,
+ PART_DRAW_CROSS = 3,
+ PART_DRAW_AXIS = 4,
+ PART_DRAW_LINE = 5,
+ PART_DRAW_PATH = 6,
+ PART_DRAW_OB = 7,
+ PART_DRAW_GR = 8,
+ PART_DRAW_BB = 9,
+ PART_DRAW_REND = 10,
+ PART_DRAW_HULL = 11,
+} eParticleDrawMethod;
/* part->integrator */
#define PART_INT_EULER 0
@@ -543,11 +560,13 @@ typedef enum eParticleChildFlag {
#define PSYS_DISABLED 8192
#define PSYS_OB_ANIM_RESTORE 16384 /* runtime flag */
-/* pars->flag */
-#define PARS_UNEXIST 1
-#define PARS_NO_DISP 2
-//#define PARS_STICKY 4 /* deprecated */
-#define PARS_REKEY 8
+typedef enum eParticleDataFlag {
+ PARS_UNEXIST = 1,
+ PARS_NO_DISP = 2,
+// PARS_STICKY = 4, /* deprecated */
+ PARS_REKEY = 8,
+ PARS_HAIR_BLEND = 16, /* exclude from simulation and instead blend result from surrounding hairs */
+} eParticleDataFlag;
/* pars->alive */
//#define PARS_KILLED 0 /* deprecated */
@@ -606,6 +625,9 @@ typedef enum eParticleTextureInfluence {
PAMAP_ROUGH = (1<<9),
PAMAP_LENGTH = (1<<4),
PAMAP_CHILD = (PAMAP_CLUMP | PAMAP_KINK_FREQ | PAMAP_KINK_AMP | PAMAP_ROUGH | PAMAP_LENGTH),
+ PAMAP_SHAPEKEY = (1<<13), /* shapekey blend multiplier */
+ /* color */
+ PAMAP_COLOR = (1<<14),
} eParticleTextureInfluence;
#endif