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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-06-12 13:58:31 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-06-12 13:58:31 +0300
commit43eebdfebd6e31d188ae3c1b220c8991fc869df3 (patch)
tree5adc929ce792f2dfd74276838e63d91fcddb9a1c /source/blender/collada
parentc98b2e74df2e531726f5ceabe76342282f695f23 (diff)
parentbe57cf9b2a0e1be577211839487cacd288886c1a (diff)
Merge branch 'master' into blender2.8
Conflicts: source/blender/collada/DocumentImporter.cpp source/blender/editors/include/ED_object.h source/blender/editors/object/object_modifier.c
Diffstat (limited to 'source/blender/collada')
-rw-r--r--source/blender/collada/ArmatureImporter.cpp5
-rw-r--r--source/blender/collada/ArmatureImporter.h2
-rw-r--r--source/blender/collada/DocumentImporter.cpp2
3 files changed, 5 insertions, 4 deletions
diff --git a/source/blender/collada/ArmatureImporter.cpp b/source/blender/collada/ArmatureImporter.cpp
index 19f174d4840..0e71149fba6 100644
--- a/source/blender/collada/ArmatureImporter.cpp
+++ b/source/blender/collada/ArmatureImporter.cpp
@@ -856,8 +856,9 @@ bool ArmatureImporter::write_controller(const COLLADAFW::Controller *controller)
return true;
}
-void ArmatureImporter::make_shape_keys()
+void ArmatureImporter::make_shape_keys(bContext *C)
{
+ Main *bmain = CTX_data_main(C);
std::vector<COLLADAFW::MorphController *>::iterator mc;
float weight;
@@ -873,7 +874,7 @@ void ArmatureImporter::make_shape_keys()
Mesh *source_me = (Mesh *)source_ob->data;
//insert key to source mesh
- Key *key = source_me->key = BKE_key_add((ID *)source_me);
+ Key *key = source_me->key = BKE_key_add(bmain, (ID *)source_me);
key->type = KEY_RELATIVE;
KeyBlock *kb;
diff --git a/source/blender/collada/ArmatureImporter.h b/source/blender/collada/ArmatureImporter.h
index b13e40bf855..58121a090fa 100644
--- a/source/blender/collada/ArmatureImporter.h
+++ b/source/blender/collada/ArmatureImporter.h
@@ -146,7 +146,7 @@ public:
// here we add bones to armatures, having armatures previously created in write_controller
void make_armatures(bContext *C, std::vector<Object *> &objects_to_scale);
- void make_shape_keys();
+ void make_shape_keys(bContext *C);
#if 0
// link with meshes, create vertex groups, assign weights
diff --git a/source/blender/collada/DocumentImporter.cpp b/source/blender/collada/DocumentImporter.cpp
index aab5a4ecfa9..d80f7c20139 100644
--- a/source/blender/collada/DocumentImporter.cpp
+++ b/source/blender/collada/DocumentImporter.cpp
@@ -244,7 +244,7 @@ void DocumentImporter::finish()
armature_importer.set_tags_map(this->uid_tags_map);
armature_importer.make_armatures(mContext, *objects_to_scale);
- armature_importer.make_shape_keys();
+ armature_importer.make_shape_keys(mContext);
DEG_relations_tag_update(bmain);
#if 0