1.0.15 • Published 7 years ago
@extra-youtube/video v1.0.15
Get video from audio, image.
setup
- Create filestack account, and set FILESTACK_APIKEYenvironment variable.
usage
const video = require('@extra-youtube/video');
// video(<output>, <audio>, <image>, [options])
// -> Promise <output>
// [options]: {
//   output: {
//     image: $EYOUTUBE_OUTPUT_IMAGE||false
//   },
//   video: {
//     loop: $EYOUTUBE_VIDEO_LOOP||1,
//     framerate: $EYOUTUBE_VIDEO_FRAMERATE||1,
//     vcodec: $EYOUTUBE_VIDEO_VCODEC||'libx264',
//     crf: $EYOUTUBE_VIDEO_CRF||0,
//     preset: $EYOUTUBE_VIDEO_PRESET||'veryfast',
//     tune: $EYOUTUBE_VIDEO_TUNE||'stillimage',
//     acodec: $EYOUTUBE_VIDEO_ACODEC||'copy'
//     cp: {
//       sync: true,
//       stdio: [0, 1, 2]
//     }
//   },
//   image: {
//     convert: {
//       apiKey: $CLOUDCONVERT_APIKEY
//     }
//   }
// }
var img = 'https://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/Tanglanglapass.jpg/800px-Tanglanglapass.jpg';
await video('output.mp4', 'input.mp3', img);
// output.mp4 createdReferences: filestack convert.
