I am trying to have an output video using ffmpeg with:
- a base video "video.mp4"
- a static overlay image "staticimage.png"
- an overlay image that makes looping transition left-right "movingimage.png"
Here is what I could make so far:
ffmpeg -i "video.mp4" -i "movingimage.png" -i "staticimage.png" -filter_complex "[0]overlay=x='if(gte(t,0), -w+(t)*100, 3)':y=0[v];[v][2]overlay=0:0[vt];[1][vt]overlay=0:0" -c:a copy -vcodec libx264 -preset superfast -f flv "output.flv"
This command is successful so far. However the moving image only does one transition. Is there a way to make it loop and start all over again for the initial position (left)?
Your help will be appreciated. Thank you.