Patch to FFmpeg::Command to support multiple input files

| 2 Comments | No TrackBacks

The FFmpeg::Command Perl module is a convenient way to drive the ffmpeg command-line utility for converting multimedia files.

For work, I have developed some scripts that make heavy use of FFmpeg::Command. Yesterday, one of the other developers told me they need a conversion script to be able to merge separate video and audio streams into one file that contains both audio and video. The ffmpeg command-line utility can do this by accepting more than one input file. For example:

$ ffmpeg -i video.avi -i audio.wav -acodec copy -vcodec copy merged.avi

The FFmpeg::Command Perl module, however, assumed there can only be one input file. I made the necessary changes to the module code so that it would accept multiple input files, created a patch file, and sent it to the Module owner Gosuke Miyashita. This morning, I received e-mail from Gosuke thanking me for the patch and informing me that he has uploaded a new version (v0.12) of FFmpeg::Command to CPAN.

I love Perl and open source software!

No TrackBacks

TrackBack URL: http://fozzolog.fozzilinymoo.org/mt-tb.cgi/1671

2 Comments

one of the other developers told me they need a conversion script to be able to merge separate video and audio streams into one file that contains both audio and video. The ffmpeg command-line utility can do this by accepting more than one input file.

Yes! This is one of the changes I added.

input_file( @files );

Leave a comment

About this Entry

This page contains a single entry by Doran L. Barton published on November 13, 2009 9:43 AM.

Hulu Desktop on Fedora 11 x86_64 was the previous entry in this blog.

Recompiling ffmpeg for Fedora 12 to add faac support is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.