I have a given source video which is 30 seconds long in total.
Now I want to trimm the first 5 seconds and apply the boomerang effect on it. That's the command where I am currently:
ffmpeg -i src.mp4 -y -an -filter_complex "[0]trim=start=0:end=5[a];[a]reverse[r];[a][r]concat,loop=0:250,setpts=N/30/TB" out.mp4
Im relatively new to ffmpeg and I'm trying to understand the principals, but I struggle with it a bit. After reading some docs, I understanded that the first brackets [0] are the source stream for the manipulation and the leading ending brackets are the output stream name, so I can continue to process it with other manipulations like concat etc.
That's what I tried with [a], which should act as the output stream of my trimed video. But this didn't worked well.
Another approach what I found is to use -ss 0 -t 5
,but this would trim it at the end of the processing, what would be inefficient since ffmpeg would apply my manipulation on the complete 30 seconds and throw away the 25secs afterwards.
What did I understand wrong and how can I fix it ?
question from:
https://stackoverflow.com/questions/65874316/trim-a-video-and-add-the-boomerang-effect-on-it-with-ffmpeg 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…