This module is heavily inspired by
bodymovin's ease conversions.
ae-temporal-to-cubic-ease will convert keyframe temporal (or time based) ease data exported from
ae-to-json to a cubic ease equation definition.
In the following example an JSON file which is exported via the
ae-to-json module is passed to
ae-temporal-to-cubic-ease and when a keyframe is encountered with easing a cubic bezier curve defintion which defines an an ease is added to it:
var exportFromAEtoJSON = ;var aeTemporalToCubicEase = ;var exportWithCubicEaseOutAdded = ;
An example export-
Note in the following examples a keyframe is defined as an Array with 3 elements where:
Original JSON defining a keyframe:
After running through
After running through this module a variable
easeOutCubic is added to ease definition with a variable which defines temporal/time based easing as a cubic curve. (the same way that CSS ease curves would for instance)
MIT, see LICENSE.md for details.