Page Menu
Home
Search
Configure Global Search
Log In
Paste
P1076
T69000 part 1
Active
Public
Actions
Authored by
Philipp Oeser (lichtwerk)
on Aug 21 2019, 8:08 PM.
Edit Paste
Archive Paste
View Raw File
Subscribe
Mute Notifications
Award Token
Tags
None
Subscribers
None
diff --git a/source/blender/makesrna/intern/rna_particle.c b/source/blender/makesrna/intern/rna_particle.c
index cadd66d564a..d28f5105186 100644
--- a/source/blender/makesrna/intern/rna_particle.c
+++ b/source/blender/makesrna/intern/rna_particle.c
@@ -615,7 +615,7 @@ static void rna_ParticleSystem_mcol_on_emitter(ParticleSystem *particlesystem,
}
}
-static void particle_recalc(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr, short flag)
+static void particle_recalc(Main *bmain, Scene *UNUSED(scene), PointerRNA *ptr, short flag)
{
if (ptr->type == &RNA_ParticleSystem) {
Object *ob = ptr->id.data;
@@ -626,6 +626,17 @@ static void particle_recalc(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRN
DEG_id_tag_update(&ob->id, ID_RECALC_GEOMETRY);
}
else {
+ /* This seems to be additionally needed for particle edit mode. */
+ ParticleSettings *part = ptr->data;
+ for (Object *ob = bmain->objects.first; ob; ob = ob->id.next) {
+ for (ParticleSystem *psys = ob->particlesystem.first; psys; psys = psys->next) {
+ if (psys->part == part) {
+ BKE_particle_batch_cache_dirty_tag(psys, BKE_PARTICLE_BATCH_DIRTY_ALL);
+ }
+ }
+ }
+
+ /* this is enough for object mode */
DEG_id_tag_update(ptr->id.data, ID_RECALC_GEOMETRY | flag);
}
Event Timeline
Philipp Oeser (lichtwerk)
created this paste.
Aug 21 2019, 8:08 PM
Philipp Oeser (lichtwerk)
mentioned this in
T69000: Hair: changing children related settings not updating in particle editmode (also crash when deleting a particle, then undo)
.
Aug 21 2019, 8:19 PM
Log In to Comment