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:
Diffstat (limited to 'source/blender/blenkernel/intern/object.c')
-rw-r--r--source/blender/blenkernel/intern/object.c17
1 files changed, 2 insertions, 15 deletions
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c
index 676277dae8c..6ab47f1b1f8 100644
--- a/source/blender/blenkernel/intern/object.c
+++ b/source/blender/blenkernel/intern/object.c
@@ -360,9 +360,9 @@ static void object_make_local(Main *bmain, ID *id, const int flags)
}
}
else {
- Object *ob_new = BKE_object_copy(bmain, ob);
+ Object *ob_new = (Object *)BKE_id_copy(bmain, &ob->id);
+ id_us_min(&ob_new->id);
- ob_new->id.us = 0;
ob_new->proxy = ob_new->proxy_from = ob_new->proxy_group = NULL;
/* setting newid is mandatory for complex make_lib_local logic... */
@@ -1786,19 +1786,6 @@ void BKE_object_transform_copy(Object *ob_tar, const Object *ob_src)
}
/**
- * Copy objects, will re-initialize cached simulation data.
- */
-Object *BKE_object_copy(Main *bmain, const Object *ob)
-{
- Object *ob_copy = (Object *)BKE_id_copy(bmain, &ob->id);
-
- /* We increase object user count when linking to Collections. */
- id_us_min(&ob_copy->id);
-
- return ob_copy;
-}
-
-/**
* Perform deep-copy of object and its 'children' data-blocks (obdata, materials, actions, etc.).
*
* \param dupflag: Controls which sub-data are also duplicated