diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2018-11-16 03:03:04 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2018-11-16 03:03:13 +0300 |
commit | a76540395575402be3c592d17d6c2e8efac4e127 (patch) | |
tree | 32d2d2df3f2d6661b561ef3055acd36c18373653 /source/blender/editors/object | |
parent | b24de94c29237586470ec061312f64780097ba74 (diff) |
BKE: Fix probe duplication not duplicating data block
Diffstat (limited to 'source/blender/editors/object')
-rw-r--r-- | source/blender/editors/object/object_add.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c index 0a16a62d788..a679674873c 100644 --- a/source/blender/editors/object/object_add.c +++ b/source/blender/editors/object/object_add.c @@ -79,6 +79,7 @@ #include "BKE_library.h" #include "BKE_library_query.h" #include "BKE_library_remap.h" +#include "BKE_lightprobe.h" #include "BKE_main.h" #include "BKE_material.h" #include "BKE_mball.h" @@ -2343,6 +2344,16 @@ static Base *object_add_duplicate_internal(Main *bmain, Scene *scene, ViewLayer id_us_min(id); } break; + case OB_LIGHTPROBE: + if (dupflag != 0) { + ID_NEW_REMAP_US2(obn->data) + else { + obn->data = ID_NEW_SET(obn->data, BKE_lightprobe_copy(bmain, obn->data)); + didit = 1; + } + id_us_min(id); + } + break; case OB_SPEAKER: if (dupflag != 0) { ID_NEW_REMAP_US2(obn->data) |