Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2018-06-22 15:42:03 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-06-25 14:35:41 +0300
commita99dcab148ed209409f3b2479ada12d869ae84b6 (patch)
tree2b7fc55752cbe3538fc05c8f77fd86b18a0d6df7 /source/blender/blenkernel/intern/particle_system.c
parent5b3ff9f7d890554ae87e63095f24ac6d31a36d3c (diff)
Depsgraph: cache collision relations, for performance and stability.
Same reasoning as effector relations in earlier commit.
Diffstat (limited to 'source/blender/blenkernel/intern/particle_system.c')
-rw-r--r--source/blender/blenkernel/intern/particle_system.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/particle_system.c b/source/blender/blenkernel/intern/particle_system.c
index d6a29531482..e8dbf95e286 100644
--- a/source/blender/blenkernel/intern/particle_system.c
+++ b/source/blender/blenkernel/intern/particle_system.c
@@ -1310,7 +1310,7 @@ static void psys_update_effectors(ParticleSimulationData *sim)
{
BKE_effectors_free(sim->psys->effectors);
sim->psys->effectors = BKE_effectors_create(sim->depsgraph,
- sim->scene, sim->ob, sim->psys,
+ sim->ob, sim->psys,
sim->psys->part->effector_weights);
precalc_guides(sim, sim->psys->effectors);
}
@@ -3540,7 +3540,7 @@ static void dynamics_step(ParticleSimulationData *sim, float cfra)
psys_update_effectors(sim);
if (part->type != PART_HAIR)
- sim->colliders = get_collider_cache(sim->scene, sim->ob, part->collision_group);
+ sim->colliders = BKE_collider_cache_create(sim->depsgraph, sim->ob, part->collision_group);
/* initialize physics type specific stuff */
switch (part->phystype) {
@@ -3747,7 +3747,7 @@ static void dynamics_step(ParticleSimulationData *sim, float cfra)
pa->state.time=cfra;
}
- free_collider_cache(&sim->colliders);
+ BKE_collider_cache_free(&sim->colliders);
BLI_rng_free(sim->rng);
sim->rng = NULL;
}