ms-to-frames

1.0.2 • Public • Published

ms-to-frames

A simple way to turn milliseconds into frames (if that is something you need done)

Tested with 25, 30, 50, 60 (but will likely work for all other variations).

Install

npm install ms-to-frames

Usage

const msToFrames = require("ms-to-frames");

// Convert 1000ms to frames at 25fps
msToFrames.convert(1000, "25");
// -> 25

// Convert 156200ms to frames at 30fps
msToFrames.convert(156200, "30");
// -> 4686

Package Sidebar

Install

npm i ms-to-frames

Weekly Downloads

2

Version

1.0.2

License

MIT

Unpacked Size

2.51 kB

Total Files

5

Last publish

Collaborators

  • iamjohnbarker