diff options
-rw-r--r-- | source/blender/blenkernel/intern/anim_sys.c | 12 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_anim.c | 5 |
2 files changed, 16 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/anim_sys.c b/source/blender/blenkernel/intern/anim_sys.c index cc5cd3b03ae..663eb4027f6 100644 --- a/source/blender/blenkernel/intern/anim_sys.c +++ b/source/blender/blenkernel/intern/anim_sys.c @@ -1893,6 +1893,10 @@ static void animsys_evaluate_fcurves(Depsgraph *depsgraph, if ((fcu->flag & (FCURVE_MUTED | FCURVE_DISABLED))) { continue; } + /* Skip empty curves, as if muted. */ + if (fcu->totvert == 0) { + continue; + } PathResolvedRNA anim_rna; if (animsys_store_rna_setting(ptr, fcu->rna_path, fcu->array_index, &anim_rna)) { const float curval = calculate_fcurve(&anim_rna, fcu, ctime); @@ -2005,7 +2009,7 @@ void animsys_evaluate_action_group(PointerRNA *ptr, bAction *act, bActionGroup * /* calculate then execute each curve */ for (fcu = agrp->channels.first; (fcu) && (fcu->grp == agrp); fcu = fcu->next) { /* check if this curve should be skipped */ - if ((fcu->flag & (FCURVE_MUTED | FCURVE_DISABLED)) == 0) { + if ((fcu->flag & (FCURVE_MUTED | FCURVE_DISABLED)) == 0 && fcu->totvert != 0) { PathResolvedRNA anim_rna; if (animsys_store_rna_setting(ptr, fcu->rna_path, fcu->array_index, &anim_rna)) { const float curval = calculate_fcurve(&anim_rna, fcu, ctime); @@ -3101,6 +3105,9 @@ static void nlastrip_evaluate_actionclip(PointerRNA *ptr, if ((fcu->grp) && (fcu->grp->flag & AGRP_MUTED)) { continue; } + if (fcu->totvert == 0) { + continue; + } /* evaluate the F-Curve's value for the time given in the strip * NOTE: we use the modified time here, since strip's F-Curve Modifiers @@ -3327,6 +3334,9 @@ static void nla_eval_domain_action(PointerRNA *ptr, if ((fcu->grp) && (fcu->grp->flag & AGRP_MUTED)) { continue; } + if (fcu->totvert == 0) { + continue; + } NlaEvalChannel *nec = nlaevalchan_verify(ptr, channels, fcu->rna_path); diff --git a/source/blender/editors/interface/interface_anim.c b/source/blender/editors/interface/interface_anim.c index b9de504f3b2..e34d67b6996 100644 --- a/source/blender/editors/interface/interface_anim.c +++ b/source/blender/editors/interface/interface_anim.c @@ -82,6 +82,11 @@ void ui_but_anim_flag(uiBut *but, float cfra) if (fcu) { if (!driven) { + /* Empty curves are ignored by the animation evaluation system. */ + if (fcu->totvert == 0) { + return; + } + but->flag |= UI_BUT_ANIMATED; /* T41525 - When the active action is a NLA strip being edited, |