Commit: 4b614d9e942d5bb75031cca22d43858c7dc386d5 Author: Martin Felke Date: Sat Jan 12 14:46:39 2019 +0100 Branches: temp-fracture-modifier-2.8 https://developer.blender.org/rB4b614d9e942d5bb75031cca22d43858c7dc386d5
anim bind rotation fix (again) =================================================================== M source/blender/blenkernel/intern/fracture.c =================================================================== diff --git a/source/blender/blenkernel/intern/fracture.c b/source/blender/blenkernel/intern/fracture.c index 376343bcc18..8a56b984f9a 100644 --- a/source/blender/blenkernel/intern/fracture.c +++ b/source/blender/blenkernel/intern/fracture.c @@ -1568,7 +1568,8 @@ void BKE_fracture_animated_loc_rot(FractureModifierData *fmd, Object *ob, bool d Mesh *dm = NULL; int totvert, count = 0, i = 0, *orig_index = NULL, totpoly, items; KDTree *tree = NULL; - float anim_imat[4][4], imat[4][4]; + float anim_imat[4][4], imat[4][4], anim_quat[4]; + Object *ob_eval; bool mesh_free = false; Scene* scene= DEG_get_input_scene(depsgraph); @@ -1591,6 +1592,7 @@ void BKE_fracture_animated_loc_rot(FractureModifierData *fmd, Object *ob, bool d invert_m4_m4(anim_imat, fmd->anim_mesh_ob->obmat); invert_m4_m4(imat, ob->obmat); + mat4_to_quat(anim_quat, fmd->anim_mesh_ob->obmat); if (do_bind) { @@ -1828,13 +1830,7 @@ void BKE_fracture_animated_loc_rot(FractureModifierData *fmd, Object *ob, bool d if (fmd->flag & MOD_FRACTURE_USE_ANIMATED_MESH_ROTATION) { - float ob_quat[4], anim_quat[4]; - mat4_to_quat(ob_quat, ob->obmat); - mat4_to_quat(anim_quat, fmd->anim_mesh_ob->obmat); - - mul_qt_qtqt(quat, ob_quat, quat); mul_qt_qtqt(quat, anim_quat, quat); - copy_qt_qt(mi->rigidbody->orn, quat); } _______________________________________________ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs