So you want to publish that nice family video in your page/blog/intranet without forcing your visitors to download, install and activate some obscure browser plugin and *then* wait for a 200MB download… Well.. That’s easy as cake!
First, let’s use ffmpeg to convert the video from avi, mpg or mov to something that we can stream to a nice Flash video player:
$ sudo aptitude install ffmpeg $ ffmpeg -i video.mpg -ar 11025 -s 320x240 video.flv
Then we extract the first frame of the video to use it as a thumbnail:
$ ffmpeg -y -i video.mpg -f image2 -ss 5 -vframes 1 -s 320x240 -an video.jpg
Of course, real men brew their own Flash video players using Ming. The rest of us have to settle for one that has been pre-made, like Jeroen Wijering’s most excellent Flash Video Player. To insert the video in a web page you just have to write
You know, there’s even a neat wordpress plugin that allows a much simpler syntax:
[flv:/path/to/video.flv 320 240]
Cool, eh? Now you are ready to take over YouTube!
[tags]flash, video, flvplayer, ming, ffmpeg, wordpress[/tags]