All Downloads are FREE. Search and download functionalities are using the official Maven repository.

package.dist.velocity.cjs.js Maven / Gradle / Ivy

There is a newer version: 10.17.0
Show newest version
'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

/*
  Convert velocity into velocity per second

  @param [number]: Unit per frame
  @param [number]: Frame duration in ms
*/
function velocityPerSecond(velocity, frameDuration) {
    return frameDuration ? velocity * (1000 / frameDuration) : 0;
}

exports.velocityPerSecond = velocityPerSecond;




© 2015 - 2024 Weber Informatics LLC | Privacy Policy