Blender videos

Encode image sequence to MPEG4 video

Today something very simple: use ffmpeg to encode an image sequence as a MPEG4 video:

ffmpeg -f image2 -i filename-%04d.png -vcodec mpeg4 -b 6000k output.mp4

I often use blender or custom software to render out a bunch of images. Blender usually names output files filename-0000.png, where 0000 is the frame number.  So ffmpeg can generate those filenames with the usual printf style format. You can of course tweak ffmpeg’s output via a myriad of options. But this here will simply generate a 25fps mpeg4 file, which is easily embedded for example into your Keynote presentation. On OS X you can get ffmpeg for example via MacPorts: sudo port install ffmpeg, and Linux distros usually have a package for ffmpeg as well.

iTunes OS X videos

iTunes and non MP4/MOV videos

There is a nice little blog entry which explains how to convince iTunes to take other media into your media library. The command is:

SetFile -t “MooV” -c “TVOD” some-movie.avi 

When you’ve installed Perian, iTunes should then accept almost any movie, be it avi, mkv or xvid.