From f89fc824aae4212391e26a8b9db62bfe69ae05d6 Mon Sep 17 00:00:00 2001 From: Janne Karhu Date: Wed, 9 Mar 2011 14:18:33 +0000 Subject: Fix for [#26372] Objects as PS Hair displays and renders differently * Grid distribution isn't really suited for hair, so this is now disabled. * Setting a jittered distribution with particles/face = 1 now creates particles on the center of faces. * Quite a bit of cleanup of the whole particle distribution code. --- source/blender/blenkernel/intern/anim.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'source/blender/blenkernel/intern/anim.c') diff --git a/source/blender/blenkernel/intern/anim.c b/source/blender/blenkernel/intern/anim.c index 39fea333cbc..2e1fbf2917a 100644 --- a/source/blender/blenkernel/intern/anim.c +++ b/source/blender/blenkernel/intern/anim.c @@ -1346,8 +1346,6 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p /* for groups, pick the object based on settings */ if(part->draw&PART_DRAW_RAND_GR) b= BLI_rand() % totgroup; - else if(part->from==PART_FROM_PARTICLE) - b= pa_num % totgroup; else b= a % totgroup; @@ -1402,7 +1400,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p dob= new_dupli_object(lb, go->ob, mat, par->lay, counter, OB_DUPLIPARTS, animated); copy_m4_m4(dob->omat, obcopylist[b].obmat); if(G.rendering) - psys_get_dupli_texture(par, part, sim.psmd, pa, cpa, dob->uv, dob->orco); + psys_get_dupli_texture(psys, part, sim.psmd, pa, cpa, dob->uv, dob->orco); } } else { @@ -1434,7 +1432,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p dob= new_dupli_object(lb, ob, mat, ob->lay, counter, GS(id->name) == ID_GR ? OB_DUPLIGROUP : OB_DUPLIPARTS, animated); copy_m4_m4(dob->omat, oldobmat); if(G.rendering) - psys_get_dupli_texture(par, part, sim.psmd, pa, cpa, dob->uv, dob->orco); + psys_get_dupli_texture(psys, part, sim.psmd, pa, cpa, dob->uv, dob->orco); } } -- cgit v1.2.3