ffmpeg-cli-wrapper icon indicating copy to clipboard operation
ffmpeg-cli-wrapper copied to clipboard

Watermark a Video

Open damogallagher opened this issue 7 years ago • 1 comments
trafficstars

Hi

I was looking at the following link for adding a watermark https://github.com/bramp/ffmpeg-cli-wrapper/issues/76

Specifically the code `FFmpegBuilder builder = new FFmpegBuilder() .setInput(infile)
.addInput(sampleWatermarkImg) .overrideOutputFiles(true) .addOutput(destFile)
.setVideoCodec(codec)
.addExtraArgs(extraArgs)
.setVideoFrameRate(24, 1)
.setVideoResolution( iwidth , newHeight) .setComplexVideoFilter("overlay=main_w-overlay_w-10:main_h-overlay_h-10") .setStrict(FFmpegBuilder.Strict.EXPERIMENTAL) .done();

log.debug( "Running ffmpeg as " + builder.getExecString());` However with the current version of the code - the method setComplexVideoFilter doesnt exist Which method should I be using?

Thank you Damien

damogallagher avatar Dec 03 '17 15:12 damogallagher

In case of anyone else struggled with the same issue: You should use .setComplexFilter() not .setComplexVideoFilter() and use it before .addOutput() !!

m7mdtiger avatar Jun 02 '20 14:06 m7mdtiger