From b44201d8b91011434b6edbbabd7784160cb94cc6 Mon Sep 17 00:00:00 2001 From: Joshua Leung Date: Fri, 27 Feb 2015 19:36:13 +1300 Subject: Fix for NLA Solo/Mute behaviour The Solo and Mute functionality for the NLA system should really be mutually exclusive features. They both affect whether a given track applies or not. The only difference is that the Solo option mutes all the others, while the Mute only does this on a per track basis. Before this fix, muting a strip and then making it solo meant that the solo'd track would not play at all, which isn't really what we want. --- source/blender/blenkernel/intern/anim_sys.c | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) (limited to 'source/blender/blenkernel/intern/anim_sys.c') diff --git a/source/blender/blenkernel/intern/anim_sys.c b/source/blender/blenkernel/intern/anim_sys.c index 8e2b3de9586..effe32a8079 100644 --- a/source/blender/blenkernel/intern/anim_sys.c +++ b/source/blender/blenkernel/intern/anim_sys.c @@ -2465,13 +2465,19 @@ static void animsys_evaluate_nla(ListBase *echannels, PointerRNA *ptr, AnimData if ((adt->flag & ADT_NLA_EDIT_ON) && (nlt->flag & NLATRACK_DISABLED)) break; - /* skip if we're only considering a track tagged 'solo' */ - if ((adt->flag & ADT_NLA_SOLO_TRACK) && (nlt->flag & NLATRACK_SOLO) == 0) - continue; - /* skip if track is muted */ - if (nlt->flag & NLATRACK_MUTED) - continue; - + /* solo and muting are mutually exclusive... */ + if (adt->flag & ADT_NLA_SOLO_TRACK) { + /* skip if there is a solo track, but this isn't it */ + if ((nlt->flag & NLATRACK_SOLO) == 0) + continue; + /* else - mute doesn't matter */ + } + else { + /* no solo tracks - skip track if muted */ + if (nlt->flag & NLATRACK_MUTED) + continue; + } + /* if this track has strips (but maybe they won't be suitable), set has_strips * - used for mainly for still allowing normal action evaluation... */ -- cgit v1.2.3