diff options
Diffstat (limited to 'source/blender/ikplugin/intern/itasc_plugin.cpp')
-rw-r--r-- | source/blender/ikplugin/intern/itasc_plugin.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/ikplugin/intern/itasc_plugin.cpp b/source/blender/ikplugin/intern/itasc_plugin.cpp index 9317f14b7f1..2878bbb6da7 100644 --- a/source/blender/ikplugin/intern/itasc_plugin.cpp +++ b/source/blender/ikplugin/intern/itasc_plugin.cpp @@ -586,10 +586,10 @@ static bool target_callback(const iTaSC::Timestamp ×tamp, float chanmat[4][4]; copy_m4_m4(chanmat, pchan->pose_mat); copy_v3_v3(chanmat[3], pchan->pose_tail); - mul_m4_series(restmat, target->owner->obmat, chanmat, target->eeRest); + mul_m4_series(restmat, target->owner->object_to_world, chanmat, target->eeRest); } else { - mul_m4_m4m4(restmat, target->owner->obmat, target->eeRest); + mul_m4_m4m4(restmat, target->owner->object_to_world, target->eeRest); } /* blend the target */ blend_m4_m4m4(tarmat, restmat, tarmat, constraint->enforce); @@ -620,10 +620,10 @@ static bool base_callback(const iTaSC::Timestamp ×tamp, ikscene->baseFrame.setValue(&chanmat[0][0]); /* iTaSC armature is scaled to object scale, scale the base frame too */ ikscene->baseFrame.p *= ikscene->blScale; - mul_m4_m4m4(rootmat, ikscene->blArmature->obmat, chanmat); + mul_m4_m4m4(rootmat, ikscene->blArmature->object_to_world, chanmat); } else { - copy_m4_m4(rootmat, ikscene->blArmature->obmat); + copy_m4_m4(rootmat, ikscene->blArmature->object_to_world); ikscene->baseFrame = iTaSC::F_identity; } next.setValue(&rootmat[0][0]); @@ -1065,7 +1065,7 @@ static void convert_pose(IK_Scene *ikscene) int a, joint; /* assume uniform scaling and take Y scale as general scale for the armature */ - scale = len_v3(ikscene->blArmature->obmat[1]); + scale = len_v3(ikscene->blArmature->object_to_world[1]); rot = ikscene->jointArray(0); for (joint = a = 0, ikchan = ikscene->channels; a < ikscene->numchan && joint < ikscene->numjoint; @@ -1105,7 +1105,7 @@ static void BKE_pose_rest(IK_Scene *ikscene) int a, joint; /* assume uniform scaling and take Y scale as general scale for the armature */ - scale = len_v3(ikscene->blArmature->obmat[1]); + scale = len_v3(ikscene->blArmature->object_to_world[1]); /* rest pose is 0 */ SetToZero(ikscene->jointArray); /* except for transY joints */ @@ -1183,7 +1183,7 @@ static IK_Scene *convert_tree( } ikscene->blArmature = ob; /* assume uniform scaling and take Y scale as general scale for the armature */ - ikscene->blScale = len_v3(ob->obmat[1]); + ikscene->blScale = len_v3(ob->object_to_world[1]); ikscene->blInvScale = (ikscene->blScale < KDL::epsilon) ? 0.0f : 1.0f / ikscene->blScale; std::string joint; @@ -1667,7 +1667,7 @@ static void create_scene(struct Depsgraph *depsgraph, Scene *scene, Object *ob, static int init_scene(Object *ob) { /* check also if scaling has changed */ - float scale = len_v3(ob->obmat[1]); + float scale = len_v3(ob->object_to_world[1]); IK_Scene *scene; if (ob->pose->ikdata) { |