UNPKG

popmotion

Version:

The animator's toolbox

7 lines 326 B
import { toDecimal } from './to-decimal'; export var smoothFrame = function (prevValue, nextValue, duration, smoothing) { if (smoothing === void 0) { smoothing = 0; } return toDecimal(prevValue + (duration * (nextValue - prevValue)) / Math.max(smoothing, duration)); }; //# sourceMappingURL=smooth-frame.js.map