Bugfix on irc report;
Static-animated particles didn't recalculate on render when used for duplicators (did work for halos). Allows material/texture ipo for animated motion.
This commit is contained in:
parent
2e33e173f2
commit
f7b8e05f8e
@ -470,11 +470,11 @@ void particle_duplilist(Scene *sce, Object *par, PartEff *paf)
|
||||
/* to give ipos in object correct offset */
|
||||
where_is_object_time(newob, ctime-pa->time);
|
||||
|
||||
where_is_particle(paf, pa, ctime, vec);
|
||||
where_is_particle(paf, pa, ctime-0.5, vec); // makes sure there's always a vec
|
||||
Mat4MulVecfl(par->obmat, vec);
|
||||
|
||||
if(paf->stype==PAF_VECT) {
|
||||
where_is_particle(paf, pa, ctime+1, vec1);
|
||||
where_is_particle(paf, pa, ctime+0.5, vec1); // makes sure there's always a vec
|
||||
Mat4MulVecfl(par->obmat, vec1);
|
||||
|
||||
VecSubf(vec1, vec1, vec);
|
||||
|
@ -1187,6 +1187,9 @@ void build_particle_system(Object *ob)
|
||||
pushdata(par, sizeof(Object));
|
||||
par= par->parent;
|
||||
}
|
||||
|
||||
/* for static particles, calculate system on current frame */
|
||||
do_mat_ipo(ma);
|
||||
|
||||
/* set it all at first frame */
|
||||
G.scene->r.cfra= cfralast= (int)floor(ftime);
|
||||
@ -1203,9 +1206,10 @@ void build_particle_system(Object *ob)
|
||||
}
|
||||
par= par->parent;
|
||||
}
|
||||
do_mat_ipo(ma);
|
||||
|
||||
|
||||
if((paf->flag & PAF_STATIC)==0) {
|
||||
do_mat_ipo(ma); // nor for static
|
||||
|
||||
where_is_object(ob);
|
||||
Mat4CpyMat4(prevobmat, ob->obmat);
|
||||
Mat4Invert(ob->imat, ob->obmat);
|
||||
|
@ -2749,6 +2749,9 @@ static void set_fullsample_flag(void)
|
||||
}
|
||||
|
||||
/* 10 times larger than normal epsilon, test it on default nurbs sphere with ray_transp */
|
||||
#ifdef FLT_EPSILON
|
||||
#undef FLT_EPSILON
|
||||
#endif
|
||||
#define FLT_EPSILON 1.19209290e-06F
|
||||
|
||||
|
||||
@ -3002,6 +3005,14 @@ void RE_rotateBlenderScene(void)
|
||||
init_render_object(ob);
|
||||
}
|
||||
}
|
||||
/* before make duplis, update particle for current frame */
|
||||
if(ob->transflag & OB_DUPLIVERTS) {
|
||||
PartEff *paf= give_parteff(ob);
|
||||
if(paf) {
|
||||
if(paf->flag & PAF_ANIMATED) build_particle_system(ob);
|
||||
}
|
||||
}
|
||||
|
||||
make_duplilist(sce, ob);
|
||||
if(ob->type==OB_MBALL) {
|
||||
init_render_object(ob);
|
||||
|
Loading…
Reference in New Issue
Block a user