Created
August 31, 2021 14:27
-
-
Save joelongstreet/4f3d35929b7e6976c423b213b0933c12 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const ffmpeg = require('fluent-ffmpeg'); | |
const c = new ffmpeg('video1.mp4') | |
.addInput('video2.mp4') | |
.on('error', function(err) { | |
console.log('an error happened: ' + err.message); | |
}) | |
.on('end', function() { | |
console.log('final video saved'); | |
}) | |
.mergeToFile('output.mp4', '/'); | |
c.run(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment