diff options
author | Joshua Leung <aligorith@gmail.com> | 2015-12-14 15:53:13 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2015-12-14 18:03:58 +0300 |
commit | 236d094865325413895853609f6af85f01fef70f (patch) | |
tree | 538500a2f06f3b15b1fe6dde21f48a0a5aa4e936 /source/blender/editors/animation/anim_draw.c | |
parent | de0119d087acb4e38488d6f472fb7d4f0de26c17 (diff) |
Fix: NLA Mapping should not apply to keyframes of Driver FCUrves
Diffstat (limited to 'source/blender/editors/animation/anim_draw.c')
-rw-r--r-- | source/blender/editors/animation/anim_draw.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/source/blender/editors/animation/anim_draw.c b/source/blender/editors/animation/anim_draw.c index f41420ad231..e8f59dde686 100644 --- a/source/blender/editors/animation/anim_draw.c +++ b/source/blender/editors/animation/anim_draw.c @@ -181,11 +181,17 @@ AnimData *ANIM_nla_mapping_get(bAnimContext *ac, bAnimListElem *ale) /* abort if rendering - we may get some race condition issues... */ if (G.is_rendering) return NULL; - /* handling depends on the type of animation-context we've got */ - if (ale) { - /* NLA Control Curves occur on NLA strips, and shouldn't be subjected to this kind of mapping */ - if (ale->type != ANIMTYPE_NLACURVE) - return ale->adt; + /* apart from strictly keyframe-related contexts, this shouldn't even happen */ + // XXX: nla and channel here may not be necessary... + if (ELEM(ac->datatype, ANIMCONT_ACTION, ANIMCONT_SHAPEKEY, ANIMCONT_DOPESHEET, + ANIMCONT_FCURVES, ANIMCONT_NLA, ANIMCONT_CHANNEL)) + { + /* handling depends on the type of animation-context we've got */ + if (ale) { + /* NLA Control Curves occur on NLA strips, and shouldn't be subjected to this kind of mapping */ + if (ale->type != ANIMTYPE_NLACURVE) + return ale->adt; + } } /* cannot handle... */ |