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:
authorTon Roosendaal <ton@blender.org>2007-12-02 21:33:14 +0300
committerTon Roosendaal <ton@blender.org>2007-12-02 21:33:14 +0300
commit71e4b3ce2256a2aea80d1728066f20756f6a438b (patch)
treeb3ad41be0cb5e8209e605b7dd1a43a248165b5bf /source/blender/blenkernel
parent1c661f19c879ebdbaa44a67d4b4ad9d871db25d2 (diff)
Another Proxy Armature bugfix:
- Library referencing didn't add the new local Ipo for constraints - Proxy command didn't set the driver object in constraint ipo to be the new proxy object.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r--source/blender/blenkernel/intern/object.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c
index 3c815e86116..b94e47492b2 100644
--- a/source/blender/blenkernel/intern/object.c
+++ b/source/blender/blenkernel/intern/object.c
@@ -1037,7 +1037,7 @@ static void copy_object_pose(Object *obn, Object *ob)
{
bPoseChannel *chan;
- copy_pose(&obn->pose, ob->pose, 1);
+ copy_pose(&obn->pose, ob->pose, 1); /* 1 = copy constraints */
for (chan = obn->pose->chanbase.first; chan; chan=chan->next){
bConstraint *con;
@@ -1049,6 +1049,14 @@ static void copy_object_pose(Object *obn, Object *ob)
ListBase targets = {NULL, NULL};
bConstraintTarget *ct;
+ if(con->ipo) {
+ IpoCurve *icu;
+ for(icu= con->ipo->curve.first; icu; icu= icu->next) {
+ if(icu->driver && icu->driver->ob==ob)
+ icu->driver->ob= obn;
+ }
+ }
+
if (cti && cti->get_constraint_targets) {
cti->get_constraint_targets(con, &targets);
@@ -1302,6 +1310,7 @@ void object_make_proxy(Object *ob, Object *target, Object *gob)
/* skip constraints, constraintchannels, nla? */
+
ob->type= target->type;
ob->data= target->data;
id_us_plus((ID *)ob->data); /* ensures lib data becomes LIB_EXTERN */