diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-07-17 21:07:50 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-07-17 21:07:50 +0400 |
commit | 21cb1f82db01f9e0a69c955569cd6af4356b63e5 (patch) | |
tree | 9ce995b13521d5fb8f1ebc93379d66ae0504ceff /source/blender/blenkernel/intern/particle.c | |
parent | 02ef91a6195db38388b12ec9c643858ba1b5be7e (diff) |
Revert part of commit 29079, cleanup of particle path drawing logic
This commit and other commits attempting to fix it broke various things. The
main thing that changed was that instead of computing children/paths in
advance as part of particle_system_update, this was moved to do it just before
drawing or rendering. I've changed back that behavior and tried to keep the
other fixes in the commit.
When the new particle system was just committed, it also worked this way but
gave various problems, and I had to remove that behavior to get things working
stable. Basically it meant that you could get have a path cache that was
outdated in various situations, and it doesn't fit well with dependency graph
evaluation order.
This fixes:
#22823: Children Particle Rendering is broken
#22733: Particle objects not displayed
#22888: SigSegV when rending hair particles
#22820: Another SigSegV when undo adding hairs in particel edit mode
Some particle setups in dupligroups.
The three bugs that the original commit fixed are now also still working in
my tests:
#21316: Hair weight drawing is wrong
#21923: Consistent Crash When Rendering Particle Scene.
#21950: Path rendering option for particles causes crash
Diffstat (limited to 'source/blender/blenkernel/intern/particle.c')
-rw-r--r-- | source/blender/blenkernel/intern/particle.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/particle.c b/source/blender/blenkernel/intern/particle.c index 96c0afedfb0..3791d808d01 100644 --- a/source/blender/blenkernel/intern/particle.c +++ b/source/blender/blenkernel/intern/particle.c @@ -433,7 +433,7 @@ void free_keyed_keys(ParticleSystem *psys) } } } -void psys_free_child_path_cache(ParticleSystem *psys) +static void free_child_path_cache(ParticleSystem *psys) { psys_free_path_cache_buffers(psys->childcache, &psys->childcachebufs); psys->childcache = NULL; @@ -451,7 +451,7 @@ void psys_free_path_cache(ParticleSystem *psys, PTCacheEdit *edit) psys->pathcache= NULL; psys->totcached= 0; - psys_free_child_path_cache(psys); + free_child_path_cache(psys); } } void psys_free_children(ParticleSystem *psys) @@ -462,7 +462,7 @@ void psys_free_children(ParticleSystem *psys) psys->totchild=0; } - psys_free_child_path_cache(psys); + free_child_path_cache(psys); } void psys_free_particles(ParticleSystem *psys) { @@ -2721,7 +2721,7 @@ void psys_cache_child_paths(ParticleSimulationData *sim, float cfra, int editupd } else { /* clear out old and create new empty path cache */ - psys_free_child_path_cache(sim->psys); + free_child_path_cache(sim->psys); sim->psys->childcache= psys_alloc_path_cache_buffers(&sim->psys->childcachebufs, totchild, ctx->steps+1); sim->psys->totchildcache = totchild; } |