I use ffmpeg to merge mp4 and png, I use two way:
use command
String cmd = "-y -i " + in.mp4 + " -i " + in.png + " -filter_complex [0:v][1:v]overlay=0:0[out] -preset veryfast -map [out] -map 1:0 -map 0:0 -codec:a copy " + out.mp4;
output file missing audio:
use command:
String cmd = "-y -i " + in.mp4 + " -i " + in.png + " -filter_complex [0:v][1:v]overlay=0:0[out] -preset veryfast -map [out] -map 0:a -codec:a copy " + out.mp4;
=> There is audio but some mp4 file cannot merge with png file Log: Stream map '0:a' matches no streams.
What is my command missing here ?