Added easing function option.

Added an option to change the easing function to use for animation.