[Bf-blender-cvs] [c24a23f] master: Fix for particle emission bug, reported on IRC by Thomas Beck (@plasmasolutions): When the particle emitter is parented to a fast moving object, the emission locations will not be interpolated over subframes. This works if the particle emitter is animated itself. Particle system evaluates the emitter location for each subframe, but has to do this for the parent objects as well to get reliable results.

Lukas Tönne noreply at git.blender.org
Wed Jan 22 16:33:16 CET 2014


Commit: c24a23f264d2c7001c61ca6e11c66b8c372e1d2a
Author: Lukas Tönne
Date:   Wed Jan 22 16:26:09 2014 +0100
https://developer.blender.org/rBc24a23f264d2c7001c61ca6e11c66b8c372e1d2a

Fix for particle emission bug, reported on IRC by Thomas Beck
(@plasmasolutions): When the particle emitter is parented to a fast
moving object, the emission locations will not be interpolated over
subframes. This works if the particle emitter is animated itself.
Particle system evaluates the emitter location for each subframe, but
has to do this for the parent objects as well to get reliable results.

===================================================================

M	source/blender/blenkernel/intern/particle_system.c

===================================================================

diff --git a/source/blender/blenkernel/intern/particle_system.c b/source/blender/blenkernel/intern/particle_system.c
index 37ca502..6c2a42d 100644
--- a/source/blender/blenkernel/intern/particle_system.c
+++ b/source/blender/blenkernel/intern/particle_system.c
@@ -1974,10 +1974,10 @@ void reset_particle(ParticleSimulationData *sim, ParticleData *pa, float dtime,
 		/* we have to force RECALC_ANIM here since where_is_objec_time only does drivers */
 		while (ob) {
 			BKE_animsys_evaluate_animdata(sim->scene, &ob->id, ob->adt, pa->time, ADT_RECALC_ANIM);
+			BKE_object_where_is_calc_time(sim->scene, ob, pa->time);
 			ob = ob->parent;
 		}
 		ob = sim->ob;
-		BKE_object_where_is_calc_time(sim->scene, ob, pa->time);
 
 		psys->flag |= PSYS_OB_ANIM_RESTORE;
 	}
@@ -5076,10 +5076,10 @@ void particle_system_update(Scene *scene, Object *ob, ParticleSystem *psys)
 	if (psys->flag & PSYS_OB_ANIM_RESTORE) {
 		while (ob) {
 			BKE_animsys_evaluate_animdata(scene, &ob->id, ob->adt, cfra, ADT_RECALC_ANIM);
+			BKE_object_where_is_calc_time(scene, ob, cfra);
 			ob = ob->parent;
 		}
 		ob = sim.ob;
-		BKE_object_where_is_calc_time(scene, ob, cfra);
 
 		psys->flag &= ~PSYS_OB_ANIM_RESTORE;
 	}




More information about the Bf-blender-cvs mailing list