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:
authorLukas Tönne <lukas.toenne@gmail.com>2015-03-25 14:26:16 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2015-03-26 14:18:40 +0300
commit1c8ee52423f0618310ec0ef036a951cd96d2e282 (patch)
tree0595c19fb621e34947098209f2b86950cf82a3e2
parentdcfbffcf578f21c5d7a2002588a8cdcb4465e3f4 (diff)
Fix for crash when using particle emission with clump/roughness curves
in a smoke sim. This interaction between sims is totally stupid and must be recoded entirely in some utopian future.
-rw-r--r--source/blender/blenkernel/intern/smoke.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/smoke.c b/source/blender/blenkernel/intern/smoke.c
index 559e1e05f3f..aa8649b1bed 100644
--- a/source/blender/blenkernel/intern/smoke.c
+++ b/source/blender/blenkernel/intern/smoke.c
@@ -66,6 +66,7 @@
#include "BKE_bvhutils.h"
#include "BKE_cdderivedmesh.h"
#include "BKE_collision.h"
+#include "BKE_colortools.h"
#include "BKE_constraint.h"
#include "BKE_customdata.h"
#include "BKE_deform.h"
@@ -1239,6 +1240,12 @@ static void emit_from_particles(Object *flow_ob, SmokeDomainSettings *sds, Smoke
sim.ob = flow_ob;
sim.psys = psys;
+ /* prepare curvemapping tables */
+ if ((psys->part->child_flag & PART_CHILD_USE_CLUMP_CURVE) && psys->part->clumpcurve)
+ curvemapping_changed_all(psys->part->clumpcurve);
+ if ((psys->part->child_flag & PART_CHILD_USE_ROUGH_CURVE) && psys->part->roughcurve)
+ curvemapping_changed_all(psys->part->roughcurve);
+
/* initialize particle cache */
if (psys->part->type == PART_HAIR) {
// TODO: PART_HAIR not supported whatsoever