diff options
Diffstat (limited to 'source/blender/blenkernel/intern/particle.c')
-rw-r--r-- | source/blender/blenkernel/intern/particle.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/particle.c b/source/blender/blenkernel/intern/particle.c index 5ec4c36177f..f71e2e9a6e9 100644 --- a/source/blender/blenkernel/intern/particle.c +++ b/source/blender/blenkernel/intern/particle.c @@ -3057,7 +3057,7 @@ void psys_cache_edit_paths(Scene *scene, Object *ob, PTCacheEdit *edit, float cf ParticleKey result; float birthtime = 0.0f, dietime = 0.0f; - float t, time = 0.0f, keytime = 0.0f, frs_sec; + float t, time = 0.0f, keytime = 0.0f /*, frs_sec */; float hairmat[4][4], rotmat[3][3], prev_tangent[3] = {0.0f, 0.0f, 0.0f}; int k, i; int steps = (int)pow(2.0, (double)pset->draw_step); @@ -3078,7 +3078,7 @@ void psys_cache_edit_paths(Scene *scene, Object *ob, PTCacheEdit *edit, float cf recalc_set = 1; } - frs_sec = (psys || edit->pid.flag & PTCACHE_VEL_PER_SEC) ? 25.0f : 1.0f; + /* frs_sec = (psys || edit->pid.flag & PTCACHE_VEL_PER_SEC) ? 25.0f : 1.0f; */ /* UNUSED */ if(pset->brushtype == PE_BRUSH_WEIGHT) { ;/* use weight painting colors now... */ @@ -4018,7 +4018,11 @@ void psys_get_particle_on_path(ParticleSimulationData *sim, int p, ParticleKey * init_particle_interpolation(sim->ob, psys, pa, &pind); do_particle_interpolation(psys, p, pa, t, &pind, state); - if(!keyed && !cached) { + if(pind.dm) { + mul_m4_v3(sim->ob->obmat, state->co); + mul_mat3_m4_v3(sim->ob->obmat, state->vel); + } + else if(!keyed && !cached && !(psys->flag & PSYS_GLOBAL_HAIR)) { if((pa->flag & PARS_REKEY)==0) { psys_mat_hair_to_global(sim->ob, sim->psmd->dm, part->from, pa, hairmat); mul_m4_v3(hairmat, state->co); |