You can do this with ffmpeg
using either the concat filter or the concat demuxer. Which one to use depends whether or not your inputs have the same parameters or not. If they do not, you may have to perform additional filtering to make everything suitable to be concatenated properly.
Example: concat filter
For inputs that vary in frame rate, width, and height:
ffmpeg -i video0 -i video1 -i video2 -i music -filter_complex \
"[0:v]fps=25,scale=1280x720,setpts=PTS-STARTPTS[v0]; \
"[1:v]fps=25,scale=1280x720,setpts=PTS-STARTPTS[v1]; \
"[2:v]fps=25,scale=1280x720,setpts=PTS-STARTPTS[v2]; \
"[v0][v1][v2]concat=n=3:v=1:a=0,format=yuv420p[v]" \
-map "[v]" -map 3:a -shortest output
If outputting mp4 consider adding -movflags +faststart
as an output option if your viewers will watch via progressive download.
Example: concat demuxer
If all of your inputs are similar then first make a list file named input.txt
:
file "/path/to/video0"
file "/path/to/video1"
file "/path/to/video2"
Then run ffmpeg
:
ffmpeg -f concat -i input.txt -i music -shortest output
Add -codec copy
if you want to stream copy instead of re-encode. This is not possible with the concat filter because filtering requires re-encoding.
Your questions
- Is it possible to map a web form to the assets listed above (located on a local server) and have the web form ultimately build the order of the video and render out to the local server?
Yes. As long as your protocol is supported by ffmpeg
. See ffmpeg -protocols
for a list supported by your build.
- If possible, would FFmpeg or Animoto API (or another) be the right choice?
It is possible with ffmpeg
, but I've never used Animoto API so I can't comment on that.
- What kind of time/resources would it take to build something like this?
That's not really possible to answer. You provided very little info and it depends on the skill of whoever is building it.
Also see