[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [33475] trunk/blender/source/blender/ blenkernel/intern/particle_system.c: Fix for [#25036] boids particle from 2 .49 opened in 2.5 is crash !?
Janne Karhu
jhkarh at gmail.com
Sun Dec 5 02:48:50 CET 2010
Revision: 33475
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=33475
Author: jhk
Date: 2010-12-05 02:48:49 +0100 (Sun, 05 Dec 2010)
Log Message:
-----------
Fix for [#25036] boids particle from 2.49 opened in 2.5 is crash !?
* Old boids didn't have all of the necessary data for the new system.
* Changed the particles code so that a check for all necessary data is always done before starting actual dynamics calculations.
Modified Paths:
--------------
trunk/blender/source/blender/blenkernel/intern/particle_system.c
Modified: trunk/blender/source/blender/blenkernel/intern/particle_system.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/particle_system.c 2010-12-05 00:08:25 UTC (rev 33474)
+++ trunk/blender/source/blender/blenkernel/intern/particle_system.c 2010-12-05 01:48:49 UTC (rev 33475)
@@ -3964,7 +3964,7 @@
fluid->buoyancy = 0.f;
}
-static void psys_changed_physics(ParticleSimulationData *sim)
+static void psys_prepare_physics(ParticleSimulationData *sim)
{
ParticleSettings *part = sim->psys->part;
@@ -4047,9 +4047,10 @@
if(psys->recalc & PSYS_RECALC_TYPE)
psys_changed_type(&sim);
- else if(psys->recalc & PSYS_RECALC_PHYS)
- psys_changed_physics(&sim);
+ /* setup necessary physics type dependent additional data if it doesn't yet exist */
+ psys_prepare_physics(&sim);
+
switch(part->type) {
case PART_HAIR:
{
More information about the Bf-blender-cvs
mailing list