Support proportional edit scaling on dopesheet keyframes
authorPhilipp Oeser <info@graphics-engineer.com>
Thu, 10 Jan 2019 13:03:52 +0000 (14:03 +0100)
committerPhilipp Oeser <info@graphics-engineer.com>
Thu, 10 Jan 2019 15:07:47 +0000 (16:07 +0100)
Fixes T60361

Reviewers: brecht

Maniphest Tasks: T60361

Differential Revision: https://developer.blender.org/D4188

source/blender/editors/transform/transform.c

index 2b2de65..055e974 100644 (file)
@@ -9181,6 +9181,9 @@ static void applyTimeScaleValue(TransInfo *t)
                                fac = floorf(fac + 0.5f);
                        }
 
+                       /* take proportional editing into account */
+                       fac = ((fac - 1.0f) * td->factor) + 1;
+
                        /* check if any need to apply nla-mapping */
                        if (adt)
                                startx = BKE_nla_tweakedit_remap(adt, startx, NLATIME_CONVERT_UNMAP);