diff options
author | Bastien Montagne <b.mont29@gmail.com> | 2020-04-01 12:30:30 +0300 |
---|---|---|
committer | Bastien Montagne <b.mont29@gmail.com> | 2020-04-01 13:39:06 +0300 |
commit | 8d63135da313b09562bb0cd4b0dd079b0ebabc64 (patch) | |
tree | c3f0223d08045139a4468f71a5b4045cea4c25a6 /source/blender | |
parent | 254748c3e7c7068a6fed97f42c7012c7c2594c3e (diff) |
Writefile: Cleanup World runtime data.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenloader/intern/writefile.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c index 78e36a49c11..7567a76f565 100644 --- a/source/blender/blenloader/intern/writefile.c +++ b/source/blender/blenloader/intern/writefile.c @@ -2399,6 +2399,9 @@ static void write_material(WriteData *wd, Material *ma, const void *id_address) static void write_world(WriteData *wd, World *wrld, const void *id_address) { if (wrld->id.us > 0 || wd->use_memfile) { + /* Clean up, important in undo case to reduce false detection of changed datablocks. */ + BLI_listbase_clear(&wrld->gpumaterial); + /* write LibData */ writestruct_at_address(wd, ID_WO, World, 1, id_address, wrld); write_iddata(wd, &wrld->id); |