diff options
author | Jacques Lucke <mail@jlucke.com> | 2019-03-05 17:24:54 +0300 |
---|---|---|
committer | Jacques Lucke <mail@jlucke.com> | 2019-03-05 17:24:54 +0300 |
commit | 7a6b46aac56b2a529370129bbedcd20f408c6352 (patch) | |
tree | 284f6c4d6b990d5acfebf3bb72c1df4bfcbd7ade /source/blender/blenkernel/BKE_particle.h | |
parent | 302bba1665154edc81addfa18d7b8bc8bff6a18d (diff) |
Fix T62163: Duplicating particle system results in crash
There were two problems:
1. `mesh_get_eval_final` has to be called with the evaluated object.
2. Particle systems have to have unique names within an object.
The depsgraph seems to use the particle system name as identifier.
This issue is actually independent of duplication.
The old code used a small hack to create unique names.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D4451
Diffstat (limited to 'source/blender/blenkernel/BKE_particle.h')
-rw-r--r-- | source/blender/blenkernel/BKE_particle.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_particle.h b/source/blender/blenkernel/BKE_particle.h index 129bd1aaa2c..715d8670071 100644 --- a/source/blender/blenkernel/BKE_particle.h +++ b/source/blender/blenkernel/BKE_particle.h @@ -353,6 +353,8 @@ void psys_reset(struct ParticleSystem *psys, int mode); void psys_find_parents(struct ParticleSimulationData *sim, const bool use_render_params); +void psys_unique_name(struct Object *object, struct ParticleSystem *psys, const char *defname); + void psys_cache_paths(struct ParticleSimulationData *sim, float cfra, const bool use_render_params); void psys_cache_edit_paths(struct Depsgraph *depsgraph, struct Scene *scene, struct Object *ob, struct PTCacheEdit *edit, float cfra, const bool use_render_params); void psys_cache_child_paths(struct ParticleSimulationData *sim, float cfra, const bool editupdate, const bool use_render_params); |