1
0
mirror of https://github.com/musix-org/musix-oss synced 2024-11-10 08:10:18 +00:00
musix-oss/node_modules/prism-media
MatteZ02 5eb0264906 fix
2019-05-30 12:06:47 +03:00
..
src fix 2019-05-30 12:06:47 +03:00
test fix 2019-05-30 12:06:47 +03:00
.eslintrc.json fix 2019-05-30 12:06:47 +03:00
.travis.yml fix 2019-05-30 12:06:47 +03:00
LICENSE fix 2019-05-30 12:06:47 +03:00
output.opus fix 2019-05-30 12:06:47 +03:00
package.json fix 2019-05-30 12:06:47 +03:00
README.md fix 2019-05-30 12:06:47 +03:00

prism-media

Build Status dependencies devDependencies

Makes programmatically transcoding media easier

npm install --save hydrabolt/prism-media

const Prism = require('prism-media');
const fs = require('fs');

const prism = new Prism();

const transcoder = prism.transcode({
  type: 'ffmpeg',
  media: './test/test.mp3',
  ffmpegArguments: [
    '-analyzeduration', '0',
    '-loglevel', '0',
    '-f', 's16le',
    '-ar', '48000',
    '-ac', '2',
  ],
});

transcoder.output.pipe(fs.createWriteStream('./test/test.pcm'));