[Bf-blender-cvs] [a7ed1db] master: Fix T39319: Particle System Bug on Cycles Render.
Lukas Tönne
noreply at git.blender.org
Tue Mar 25 12:39:54 CET 2014
Commit: a7ed1db51fa32a80b943816d354b45b413d98fa3
Author: Lukas Tönne
Date: Tue Mar 25 12:33:07 2014 +0100
https://developer.blender.org/rBa7ed1db51fa32a80b943816d354b45b413d98fa3
Fix T39319: Particle System Bug on Cycles Render.
Crashes due to bad dm face calculation in particle RNA/cycles hair.
This stuff is a total mess, but this kind of check is used in other
places and prevents crashing at least.
===================================================================
M source/blender/makesrna/intern/rna_particle.c
===================================================================
diff --git a/source/blender/makesrna/intern/rna_particle.c b/source/blender/makesrna/intern/rna_particle.c
index 31e87f4..f6f133c 100644
--- a/source/blender/makesrna/intern/rna_particle.c
+++ b/source/blender/makesrna/intern/rna_particle.c
@@ -475,7 +475,8 @@ static void rna_ParticleSystem_uv_on_emitter(ParticleSystem *particlesystem, Rep
if (particle_no < totpart) {
/* get uvco & mcol */
- num = particle->num_dmcache;
+ num = (ELEM(particle->num_dmcache, DMCACHE_ISCHILD, DMCACHE_NOTFOUND)) ?
+ particle->num : particle->num_dmcache;
if (num == DMCACHE_NOTFOUND)
if (particle->num < modifier->dm->getNumTessFaces(modifier->dm))
More information about the Bf-blender-cvs
mailing list