Polyfill for WebCodecs, powered by ffmpeg.wasm
Go to file
2019-10-25 19:31:39 +08:00
.github Test node 10 only 2019-10-23 21:34:56 +08:00
docs/images Update README.md icon 2019-10-25 19:29:04 +08:00
examples Init commit 2019-10-20 22:37:37 +08:00
scripts Add webpack 2019-10-23 21:52:04 +08:00
src Add eslint & update README 2019-10-23 20:46:03 +08:00
tests/assets Init commit 2019-10-20 22:37:37 +08:00
_config.yml Set theme jekyll-theme-cayman 2019-10-25 19:22:25 +08:00
.eslintrc Disable linebreak-style in .eslintrc 2019-10-25 19:15:47 +08:00
.gitattributes Init commit 2019-10-20 22:37:37 +08:00
.gitignore Add webpack 2019-10-23 21:52:04 +08:00
.npmignore Add eslint & update README 2019-10-23 20:46:03 +08:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md 2019-10-23 14:21:41 +08:00
CONTRIBUTING.md Create CONTRIBUTING.md 2019-10-23 14:22:11 +08:00
LICENSE Create LICENSE 2019-10-23 14:20:17 +08:00
package-lock.json Update package.json 2019-10-25 19:12:30 +08:00
package.json Update package.json 2019-10-25 19:12:30 +08:00
README.md Use ffmpeg.js in README.md 2019-10-25 19:31:39 +08:00

ffmpeg.js

ffmpeg.js

Actions Status Maintenance License: MIT Code Style Downloads Total Downloads Month

A FFmpeg WebAssembly version built from scratch, you can learn how to do it from this series of stories: Build FFmpeg WebAssembly version (=ffmpeg.js).


Installation

$ npm install @ffmpeg/ffmpeg

Example

const fs = require('fs');
const ffmpeg = require('@ffmpeg/ffmpeg');

(async () => {
  await ffmpeg.load();
  const data = ffmpeg.transcode('./test.avi', 'mp4');
  fs.wrieFileSync('./test.mp4', data);
})();