[Bf-blender-cvs] [b5feb19] master: f-curve easing: make ease-out symmetrical to ease-in

Campbell Barton noreply at git.blender.org
Mon Apr 28 19:23:13 CEST 2014


Commit: b5feb1940d3e1f7198b8fc72f2f9fec192e38d1e
Author: Campbell Barton
Date:   Tue Apr 29 03:20:11 2014 +1000
https://developer.blender.org/rBb5feb1940d3e1f7198b8fc72f2f9fec192e38d1e

f-curve easing: make ease-out symmetrical to ease-in

===================================================================

M	source/blender/blenlib/intern/easing.c

===================================================================

diff --git a/source/blender/blenlib/intern/easing.c b/source/blender/blenlib/intern/easing.c
index c767c62..62e4b58 100644
--- a/source/blender/blenlib/intern/easing.c
+++ b/source/blender/blenlib/intern/easing.c
@@ -182,7 +182,8 @@ float BLI_easing_elastic_ease_out(float time, float begin, float change, float d
 	else
 		s = period / (2 * (float)M_PI) * asinf(change / amplitude);
 
-	return (amplitude * powf(2, -10 * time) * sinf((time * duration - s) * (2 * (float)M_PI) / period) + change + begin);
+	time = -time;
+	return (amplitude * powf(2, 10 * time) * sinf((time * duration - s) * (2 * (float)M_PI) / period) + change + begin);
 }
 
 float BLI_easing_elastic_ease_in_out(float time, float begin, float change, float duration, float amplitude, float period)




More information about the Bf-blender-cvs mailing list