Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function convert(input, output, callback) {
- if (debug) {
- console.log("CONVERTING");
- console.log("IN: " + input);
- console.log("OUT: " + output);
- }
- ffmpeg(input)
- .outputOptions([
- "-i clipdrop_logo.png", // Logo WaterMark Input
- "-loglevel panic",
- "-preset veryfast",
- "-movflags faststart",
- "-vf scale=-1:480",
- "-c:v libx264",
- "-crf 23",
- "-c:a aac",
- "-bitrate 2000000",
- "-maxrate 2200000",
- "-bufsize 1500000",
- "-filter_complex \"overlay=main_w-overlay_w-5:main_h-overlay_h-5\"" // Logo WaterMark Settings
- ])
- .on("end", function () {
- if (debug) {
- console.log("conversion ended");
- }
- callback(null);
- })
- .on("error", function (err) {
- if (debug) {
- console.log("error x: ", err);
- }
- callback(err);
- })
- .saveToFile(output);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement