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:
authorSergey Sharybin <sergey.vfx@gmail.com>2019-06-21 12:49:43 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2019-06-21 13:09:45 +0300
commit7070e4c15e6c57da2bd46534e654ed5f9a1e6600 (patch)
tree221ceb5195fd6d98d4485db40e78d16a379107c5 /source/blender/blenkernel/intern/object.c
parent964e319a39abfe3808fded71dcacd296401ec04d (diff)
Revert "Particle system: Move runtime data to runtime field"
This reverts commit 36faf739a71624b6ca10cec7233779f9eeace0bd. Somewhat annoying but this change had some unforeseen consequences, which lead to an actual bug. Since this change was not sufficient to get original report fixed is easier to simply revert for now. Fixes T65842: Hair disappears when clicking on particle system name
Diffstat (limited to 'source/blender/blenkernel/intern/object.c')
-rw-r--r--source/blender/blenkernel/intern/object.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c
index e74b2b0f671..2a66edc8d42 100644
--- a/source/blender/blenkernel/intern/object.c
+++ b/source/blender/blenkernel/intern/object.c
@@ -497,13 +497,12 @@ void BKE_object_free_caches(Object *object)
for (md = object->modifiers.first; md != NULL; md = md->next) {
if (md->type == eModifierType_ParticleSystem) {
ParticleSystemModifierData *psmd = (ParticleSystemModifierData *)md;
- ParticleSystemModifierDataRuntime *psmd_runtime = BKE_particle_modifier_runtime_ensure(psmd);
- if (psmd_runtime->mesh_final) {
- BKE_id_free(NULL, psmd_runtime->mesh_final);
- psmd_runtime->mesh_final = NULL;
- if (psmd_runtime->mesh_original) {
- BKE_id_free(NULL, psmd_runtime->mesh_original);
- psmd_runtime->mesh_original = NULL;
+ if (psmd->mesh_final) {
+ BKE_id_free(NULL, psmd->mesh_final);
+ psmd->mesh_final = NULL;
+ if (psmd->mesh_original) {
+ BKE_id_free(NULL, psmd->mesh_original);
+ psmd->mesh_original = NULL;
}
psmd->flag |= eParticleSystemFlag_file_loaded;
update_flag |= ID_RECALC_GEOMETRY;