forked from bartvdbraak/blender
Fix for bug #7872: setting particles disp to 100 has no effect.
Fix for bug #7878: particle panels do not update properly when chaning particle types.
This commit is contained in:
parent
de17fd9ee5
commit
e2e8ea9ed1
@ -91,8 +91,9 @@ extern struct ListBase editNurb;
|
||||
void mainqenter (unsigned short event, short val);
|
||||
void waitcursor(int);
|
||||
void allqueue(unsigned short event, short val);
|
||||
#define REDRAWVIEW3D 0x4010
|
||||
#define REDRAWBUTSEDIT 0x4019
|
||||
#define REDRAWVIEW3D 0x4010
|
||||
#define REDRAWBUTSOBJECT 0x4018
|
||||
#define REDRAWBUTSEDIT 0x4019
|
||||
struct Material;
|
||||
extern struct Material defmaterial;
|
||||
|
||||
|
@ -2290,7 +2290,7 @@ void psys_mat_hair_to_orco(Object *ob, DerivedMesh *dm, short from, ParticleData
|
||||
psys_particle_on_dm(ob, dm, from, pa->num, pa->num_dmcache, pa->fuv, pa->foffset, vec, 0, 0, 0, orco, 0);
|
||||
|
||||
/* see psys_face_mat for why this function is called */
|
||||
transform_mesh_orco_verts(ob->data, orco, 1, 1);
|
||||
transform_mesh_orco_verts(ob->data, &orco, 1, 1);
|
||||
VECCOPY(hairmat[3],orco);
|
||||
}
|
||||
|
||||
|
@ -4377,6 +4377,10 @@ static void system_step(Object *ob, ParticleSystem *psys, ParticleSystemModifier
|
||||
|
||||
psys->recalc &= ~PSYS_TYPE;
|
||||
alloc = 1;
|
||||
|
||||
/* this is a bad level call, but currently type change
|
||||
* can happen after redraw, so force redraw from here */
|
||||
allqueue(REDRAWBUTSOBJECT, 0);
|
||||
}
|
||||
else
|
||||
oldtotpart = psys->totpart;
|
||||
@ -4428,7 +4432,7 @@ static void system_step(Object *ob, ParticleSystem *psys, ParticleSystemModifier
|
||||
/* set particles to be not calculated */
|
||||
disp= (float)get_current_display_percentage(psys)/50.0f-1.0f;
|
||||
|
||||
if(disp<1.0f) for(p=0, pa=psys->particles; p<totpart; p++,pa++){
|
||||
for(p=0, pa=psys->particles; p<totpart; p++,pa++){
|
||||
if(pa->r_rot[0] > disp)
|
||||
pa->flag |= PARS_NO_DISP;
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user