diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2016-03-28 16:37:08 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2016-03-28 16:52:59 +0300 |
commit | d336bb0765e8175e93e4f9d2c024e258a8c992e5 (patch) | |
tree | f51ce14f3cd7443faf2e8144c3d0f63ce996ad53 /source/blender/blenkernel | |
parent | 240adb90a5d43642da942a9aa1562b346ba73a4e (diff) |
Fix T47972: Blender crash showing particle system.
Do same as with faces - if no orcodata is available, fill orco with current location...
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/particle.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/particle.c b/source/blender/blenkernel/intern/particle.c index 081244c5c6b..0b8853364d6 100644 --- a/source/blender/blenkernel/intern/particle.c +++ b/source/blender/blenkernel/intern/particle.c @@ -1609,8 +1609,14 @@ void psys_particle_on_dm(DerivedMesh *dm_final, int from, int index, int index_d normalize_v3(nor); } - if (orco) - copy_v3_v3(orco, orcodata[mapindex]); + if (orco) { + if (orcodata) { + copy_v3_v3(orco, orcodata[mapindex]); + } + else { + copy_v3_v3(orco, vec); + } + } if (ornor) { dm_final->getVertNo(dm_final, mapindex, ornor); |