John Clyne
Scientific Computing Division, NCAR
12/09/2002
This document provides some guidance for transcoding a sequence of image files into high-quality animations, suitable for playback under MS Windows. The aim is to produce very high fidelity animations that may be played on an ordinary Windows laptop or desktop system, either in a standalone media player or embedded within a MS Powerpoint file. The priority is not to conserve disk space, bandwidth, or to be able to stream animations over the web. Presented below is a brief comparison of a number of codecs and encoding methods for producing such an animation. The analysis that was performed was anything but exhaustive; a good solution was sought, not necessarily the best solution. It’s entirely possible that results differing from those observed could be obtained simply by tweaking appropriate parameters.
Three different encoding/encoding-schemes combinations were examined:
For a variety of reasons, the WME9 encoder seems to be the best option for most, but not all cases. Trade offs of the various schemes are presented below, followed by step-by-step instructions for conversion of an image sequence to WME9’s video format file, .wmv.
Some observations applicable to all the encoders:
DivX is an open source mpeg4 codec and associated collection of video playback and recording tools. The software has been ported to linux, windows, and MacOS, and is claimed to have a user base of 60 million people (I read it on the web so it must be true).
An example DivX animation is available here.
The good
The bad
MPEG2 is the encoding standard used by DVD’s. It’s a lossy format, like MPEG4, but not quite as lossy. So in theory MPEG2 encoded material should look better than MPEG4.
The good
The bad
An example MPEG2 is available here. Note the goofy aspect ratio. What happened to the colors? But the text looks damn good.
Windows Media Encoder 9 is a newly released product from the Evil Empire. It’s presently in beta. WME9 appears to support and provide multiple codecs, but of course, because it’s M$, nothing is documented and WME9 is essentially a black box.
The good
The bad
A “very high quality” WME9 file is available here. A “high definition quality video” WME9 file can be found here.
If you don’t already have it, download the Windows Media Encoder 9 encoder from the M$ web site. Note, you’ll need DirectX 8.1 run-timer environment installed on your machine, also freely available from M$’s web site.
Unfortunately WME9 does not ingest image files. You have to provide WME9 with a movie file for input. And if you want a high quality encoding, you’ll need to provide a lossless movie file. Uncompressed AVI files seem to work just fine. You can convert an image sequence into an uncompressed AVI file either by using QuickTime Pro (available from Apple for $30), or under IRIX using dmconvert. Alas, one of the shared libs dmconvert relies on is broken in the present version of IRIX. To get around this problem, add /usr/local/lib/irix6.5.9 to your run-time library search path. E.g. under csh:
%
setenv LD_LIBRARY_PATH
/usr/local/lib/irix6.5.9/
Once you’ve got your search path set up, invoke dmconvert with something like:
dmconvert
-v -f avi -p video,comp=none \
myimages.????.rgb
mymovie.avi
Now you’re ready to transcode your .avi file into a .wmv file. The WME9 encoder has a wizard to guide you though the process. Use the following steps:
Thanks to fellow VETS staff members Fred Clare, Joey Mendoza, and Tim Scheitlin for their assistance in testing the various codecs.