Class BezierCurveEase
Hierarchy (View Summary)
- EasingFunction
- BezierCurveEase
Implements
Constructors
constructor
-
Instantiates a bezier function
Parameters
- x1: number = 0
Defines the x component of the start tangent in the bezier curve
- y1: number = 0
Defines the y component of the start tangent in the bezier curve
- x2: number = 1
Defines the x component of the end tangent in the bezier curve
- y2: number = 1
Defines the y component of the end tangent in the bezier curve
Returns BezierCurveEase
- x1: number = 0
Properties
x1
[0] Defines the x component of the start tangent in the bezier curve
x2
[1] Defines the x component of the end tangent in the bezier curve
y1
[0] Defines the y component of the start tangent in the bezier curve
y2
[1] Defines the y component of the end tangent in the bezier curve
Static ReadonlyEASINGMODE_ EASEIN
Interpolation follows the mathematical formula associated with the easing function.
Static ReadonlyEASINGMODE_ EASEINOUT
Interpolation uses EaseIn for the first half of the animation and EaseOut for the second half.
Static ReadonlyEASINGMODE_ EASEOUT
Interpolation follows 100% interpolation minus the output of the formula associated with the easing function.
Methods
ease
-
Given an input gradient between 0 and 1, this returns the corresponding value of the easing function.
Parameters
- gradient: number
Defines the value between 0 and 1 we want the easing value for
Returns number
the corresponding value on the curve defined by the easing function
- gradient: number
get Easing Mode
-
Gets the current easing mode.
Returns number
the easing mode
set Easing Mode
-
Sets the easing mode of the current function.
Parameters
- easingMode: number
Defines the willing mode (EASINGMODE_EASEIN, EASINGMODE_EASEOUT or EASINGMODE_EASEINOUT)
Returns void
- easingMode: number
Easing function with a bezier shape (see link below).
See