user1752708
user1752708

Reputation: 41

ffmpeg: several audio files + several images = 1 video?

I have about 500 audio clips and 500 images that I need to put together for a project I'm working on. Each video is made up of a number of audio clips and images. The order is already set by the naming (audio01.mp3 goes with image01.tiff etc). They files are divided into several folders named Chapter1, Chapter2 [...] Chapter12. The number of files in each folder differs, but the naming scheme is the same in each folder.

Each image will need to have the same exact duration as its partner audio file.

What is the best way of doing this? I've found ways of putting together 1 image with 1 audio file (http://stackoverflow.com/questions/5887311/ffmpeg-1-image-1-audio-file-1-video) or several images with one audio file (http://superuser.com/questions/356974/how-to-turn-images-into-a-video-slideshow-with-sound/356982#356982) but nothing that does exactly what I want.

I'd appreciate any help you could give me!

Upvotes: 2

Views: 867

Answers (1)

Robert Rowntree
Robert Rowntree

Reputation: 6289

its all there on ffmpeg docs..

for audio chunks you need to have raw pcm i believe.

then you simply cat them.. then add in the pics again following the samples for making mpeg/mp4 from single image or from series of images.

key docs on concat have to do with combining multiple mp4s but it works SAME way on a bunch of audio inputs that need to be combined...

http://ffmpeg.org/faq.html#How-can-I-concatenate-video-files_003f

sect. 3.14.3 in above is what u want 4 audio...

Upvotes: 1

Related Questions