Revision: 35431
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=35431
Author:   jhk
Date:     2011-03-09 15:04:09 +0000 (Wed, 09 Mar 2011)
Log Message:
-----------
Fix for [#26420] F-Curve key handles affected by NLA strip position
* NLA timing was only applied to fcurve keys, but not handles, so strange 
things happened.
* This time tweaking was missed in selections too, so fcurve handles couldn't 
be selected properly either if the NLA strip was moved from frame 1.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_graph/graph_select.c
    trunk/blender/source/blender/editors/transform/transform_conversions.c

Modified: trunk/blender/source/blender/editors/space_graph/graph_select.c
===================================================================
--- trunk/blender/source/blender/editors/space_graph/graph_select.c     
2011-03-09 14:18:33 UTC (rev 35430)
+++ trunk/blender/source/blender/editors/space_graph/graph_select.c     
2011-03-09 15:04:09 UTC (rev 35431)
@@ -239,7 +239,7 @@
                 * guess when a callback might use something different
                 */
                if (adt)
-                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 1);
+                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 
incl_handles==0);
                
                /* set horizontal range (if applicable) 
                 * NOTE: these values are only used for x-range and y-range but 
not region 
@@ -269,7 +269,7 @@
                
                /* un-apply NLA mapping from all the keyframes */
                if (adt)
-                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 1);
+                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 
incl_handles==0);
                        
                /* unapply unit corrections */
                ANIM_unit_mapping_apply_fcurve(ac->scene, ale->id, 
ale->key_data, ANIM_UNITCONV_RESTORE|ANIM_UNITCONV_ONLYKEYS);
@@ -987,7 +987,7 @@
                
                /* apply NLA mapping to all the keyframes */
                if (adt)
-                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 1);
+                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 0, 0);
                
                if (fcu->bezt) {
                        BezTriple *bezt1=fcu->bezt, *prevbezt=NULL;
@@ -1020,7 +1020,7 @@
                
                /* un-apply NLA mapping from all the keyframes */
                if (adt)
-                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 1);
+                       ANIM_nla_mapping_apply_fcurve(adt, ale->key_data, 1, 0);
                
                /* unapply unit corrections */
                ANIM_unit_mapping_apply_fcurve(ac->scene, ale->id, 
ale->key_data, ANIM_UNITCONV_RESTORE);

Modified: trunk/blender/source/blender/editors/transform/transform_conversions.c
===================================================================
--- trunk/blender/source/blender/editors/transform/transform_conversions.c      
2011-03-09 14:18:33 UTC (rev 35430)
+++ trunk/blender/source/blender/editors/transform/transform_conversions.c      
2011-03-09 15:04:09 UTC (rev 35431)
@@ -4858,9 +4858,9 @@
                                         ((cancelled == 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);
-                                               
ANIM_nla_mapping_apply_fcurve(adt, fcu, 1, 1);
+                                               
ANIM_nla_mapping_apply_fcurve(adt, fcu, 1, 0);
                                        }
                                        else
                                                posttrans_fcurve_clean(fcu);

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to