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>2013-04-18 12:58:21 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2013-04-18 12:58:21 +0400
commit4df0c46f838f7c316b10a6667705c093f067cadd (patch)
tree9620cb8dbe215e30a3738509bed50408bca2452d /source/blender/editors/object/object_relations.c
parent093f95afaa4a08d2cf194b88803a35ef16cfec58 (diff)
Make freestyle use local Main for temporary objects
This means main database is no longer pollutes with temporary scene and objects needed for freestyle render. Actually, there're few of separated temporary mains now. Ideally it's better to use single one, but it's not so much trivial to pass it to all classes. Not so big deal actually. Required some changes to blender kernel, to make it possible to add object to a given main, also to check on mesh materials for objects in given main. This is all straightforward changes. As an additional, solved issue with main database being infinitely polluted with text blocks created by create_lineset_handler function. This fixes: - #35003: Freestyle crashes if user expands objects in FRS1_Scene - #35012: ctrl+f12 rendering crashes when using Freestyle
Diffstat (limited to 'source/blender/editors/object/object_relations.c')
-rw-r--r--source/blender/editors/object/object_relations.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c
index 9ed57adf207..9838c99a81b 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -344,7 +344,7 @@ static int make_proxy_exec(bContext *C, wmOperator *op)
char name[MAX_ID_NAME + 4];
/* Add new object for the proxy */
- newob = BKE_object_add(scene, OB_EMPTY);
+ newob = BKE_object_add(bmain, scene, OB_EMPTY);
BLI_snprintf(name, sizeof(name), "%s_proxy", ((ID *)(gob ? gob : ob))->name + 2);
@@ -1459,7 +1459,7 @@ static int make_links_data_exec(bContext *C, wmOperator *op)
ob_dst->data = id;
/* if amount of material indices changed: */
- test_object_materials(ob_dst->data);
+ test_object_materials(bmain, ob_dst->data);
DAG_id_tag_update(&ob_dst->id, OB_RECALC_DATA);
break;