Fix T46037: Moving keys in NLA tweak mode on offset actions results in Bezier handles getting stretched unreasonably

Patch by Alexander Gavrilov (angavrilov)

Reviewed by Joshua Leung (aligorith)
This commit is contained in:
2016-02-06 00:59:32 +13:00
parent c53c8df6d9
commit c105c59bb4
4 changed files with 14 additions and 14 deletions

View File

@@ -3390,9 +3390,9 @@ static void posttrans_action_clean(bAnimContext *ac, bAction *act)
AnimData *adt = ANIM_nla_mapping_get(ac, ale);
if (adt) {
ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 1);
ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 0);
posttrans_fcurve_clean(ale->key_data, false); /* only use handles in graph editor */
ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 1);
ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 0);
}
else
posttrans_fcurve_clean(ale->key_data, false); /* only use handles in graph editor */
@@ -6039,9 +6039,9 @@ void special_aftertrans_update(bContext *C, TransInfo *t)
((canceled == 0) || (duplicate)) )
{
if (adt) {
ANIM_nla_mapping_apply_fcurve(adt, fcu, 0, 1);
ANIM_nla_mapping_apply_fcurve(adt, fcu, 0, 0);
posttrans_fcurve_clean(fcu, false); /* only use handles in graph editor */
ANIM_nla_mapping_apply_fcurve(adt, fcu, 1, 1);
ANIM_nla_mapping_apply_fcurve(adt, fcu, 1, 0);
}
else
posttrans_fcurve_clean(fcu, false); /* only use handles in graph editor */