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:
authorKévin Dietrich <kevin.dietrich@mailoo.org>2020-10-29 16:40:29 +0300
committerKévin Dietrich <kevin.dietrich@mailoo.org>2020-10-29 19:39:21 +0300
commit8c3d42bd0f0160ba58c6a932c0e4c228ce6b0426 (patch)
treea9e020a29c532c227e0a7be9d9c33411e4b8a807 /intern/cycles/blender/blender_particles.cpp
parent2e41db5277a5f90250f398ef3ea8777118dc34ee (diff)
Fix T82129: Cycles "Persistent Images" incorrectly retains scene data
The issue stems from the fact that scene arrays are not cleared when rendering is done. This was not really an issue before the introduction of the ownership system (rB429afe0c626a) as the id_map would recreate scene data arrays based on their new content. However, now that the id_maps do not have access to the scene data anymore the arrays are never created. Another related issue is that the BlenderSync instance is never freed when the persistent data option is activated. To fix this, we delete nodes created by the id_maps in their destructors, and delete the BlenderSync instance before creating a new one, so the id_maps destructors are actually called. Reviewed By: brecht Maniphest Tasks: T82129 Differential Revision: https://developer.blender.org/D9378
Diffstat (limited to 'intern/cycles/blender/blender_particles.cpp')
-rw-r--r--intern/cycles/blender/blender_particles.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/intern/cycles/blender/blender_particles.cpp b/intern/cycles/blender/blender_particles.cpp
index ee14217988b..e5eab1ae62b 100644
--- a/intern/cycles/blender/blender_particles.cpp
+++ b/intern/cycles/blender/blender_particles.cpp
@@ -53,8 +53,7 @@ bool BlenderSync::sync_dupli_particle(BL::Object &b_ob,
ParticleSystem *psys;
bool first_use = !particle_system_map.is_used(key);
- bool need_update = particle_system_map.add_or_update(
- scene, &psys, b_ob, b_instance.object(), key);
+ bool need_update = particle_system_map.add_or_update(&psys, b_ob, b_instance.object(), key);
/* no update needed? */
if (!need_update && !object->geometry->need_update && !scene->object_manager->need_update)