diff options
Diffstat (limited to 'source/blender/blenkernel/BKE_particle.h')
-rw-r--r-- | source/blender/blenkernel/BKE_particle.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/source/blender/blenkernel/BKE_particle.h b/source/blender/blenkernel/BKE_particle.h index 1416e1280cf..3f7523d5264 100644 --- a/source/blender/blenkernel/BKE_particle.h +++ b/source/blender/blenkernel/BKE_particle.h @@ -63,6 +63,7 @@ struct BVHTreeRayHit; #define LOOP_PARTICLES for(p=0, pa=psys->particles; p<psys->totpart; p++, pa++) #define LOOP_EXISTING_PARTICLES for(p=0, pa=psys->particles; p<psys->totpart; p++, pa++) if(!(pa->flag & PARS_UNEXIST)) #define LOOP_SHOWN_PARTICLES for(p=0, pa=psys->particles; p<psys->totpart; p++, pa++) if(!(pa->flag & (PARS_UNEXIST|PARS_NO_DISP))) +#define LOOP_DYNAMIC_PARTICLES for(p=0, pa=psys->particles; p<psys->totpart; p++, pa++) if(pa->state.time > 0.f) #define PSYS_FRAND_COUNT 1024 #define PSYS_FRAND(seed) psys->frand[(seed) % PSYS_FRAND_COUNT] @@ -171,7 +172,9 @@ typedef struct ParticleCollision float co1[3], co2[3]; // ray start and end points float ve1[3], ve2[3]; // particle velocities float ray_len; // original length of co2-co1, needed for collision time evaluation - float t; // time of previous collision, needed for substracting face velocity + float f; // time factor of previous collision, needed for substracting face velocity + float cfra; // start of the timestep (during frame change, since previous integer frame) + float dfra; // duration of timestep in frames } ParticleCollision; typedef struct ParticleDrawData { @@ -224,9 +227,9 @@ void copy_particle_key(struct ParticleKey *to, struct ParticleKey *from, int tim void psys_particle_on_emitter(struct ParticleSystemModifierData *psmd, int distr, int index, int index_dmcache, float *fuv, float foffset, float *vec, float *nor, float *utan, float *vtan, float *orco, float *ornor); struct ParticleSystemModifierData *psys_get_modifier(struct Object *ob, struct ParticleSystem *psys); -struct ModifierData *object_add_particle_system(struct Scene *scene, struct Object *ob, char *name); +struct ModifierData *object_add_particle_system(struct Scene *scene, struct Object *ob, const char *name); void object_remove_particle_system(struct Scene *scene, struct Object *ob); -struct ParticleSettings *psys_new_settings(char *name, struct Main *main); +struct ParticleSettings *psys_new_settings(const char *name, struct Main *main); struct ParticleSettings *psys_copy_settings(struct ParticleSettings *part); void make_local_particlesettings(struct ParticleSettings *part); @@ -309,7 +312,7 @@ void reset_particle(struct ParticleSimulationData *sim, struct ParticleData *pa, /* psys_reset */ #define PSYS_RESET_ALL 1 #define PSYS_RESET_DEPSGRAPH 2 -#define PSYS_RESET_CHILDREN 3 +/* #define PSYS_RESET_CHILDREN 3 */ /*UNUSED*/ #define PSYS_RESET_CACHE_MISS 4 /* index_dmcache */ |