|MPEG Library Links|
|Updated: 18 Mar 1998|
One of the first projects I worked on at the Brain Imaging Centre at the Montreal Neurological Institute was to develop a fast and flexible MPEG player for the SGI workstations used there. This was done so that we could get rid of our old PIXAR machine which, while it was state-of-the-art in 1989, was getting a little long in the tooth by 1994 (when my involvement with MPEG players started). In fact, at the end of its life (sniff!), it was only used for giving demos---hence, the impetus for an SGI MPEG player.
If all you want to do is play MPEG's on your X workstation, the classic solution is mpeg_play, an X11-based player from the Berkeley Plateau Research Group at the University of California at Berkeley. mpeg_play has no user interface to speak of (it simply plays a movie once and then quits) but I'm not griping---these guys produced an impressively efficient decoder for a portable, all-software implementation. Thanks to Daeron Meyer of the Geometry Centre at the University of Minnesota, there is a Motif-ified version of mpeg_play available. This version adds the capability to restart and loop, as well as a nice `push-button' user interface.
However, when you have a farm of Silicon Graphics workstations, you can't help but thinking MPEG playback should take better advantage of the graphics hardware. (It turns out that about the only thing the hardware gives you is fast pixel doubling/tripling/etc, but that's still better than nothing.) When those workstations have a whopping 64 MB of memory (remember, this was 1994!), you get to thinking about sucking up all that memory with a fully decoded video stream and playing it back as fast as you can shove the bits down the bus. And for giving snazzy "spinning brain" demos to visting scientists, suits, dignitaries, and TV reporters (all of whom visited on occasion), it's nice to have some more chrome then just play, pause, and restart.
That wish list led to glmpeg_play, my SGI-only, feature-heavy MPEG-1 video player. But in order to get there, first I had to hack up Berkeley's mpeg_play and extract the relevant bits. Or more accurately, remove the irrelevant bits dealing with putting decoded images into an X Window, and replace them with GL calls (GL is SGI's graphics library; it has since been superseded by OpenGL, but I never got around to modernizing glmpeg_play, so it still uses the old GL cals).
Rather than take that simplistic approach, though, I was persuaded to turn mpeg_play into a general-purpose MPEG-1 video decoding library, and make glmpeg_play a separate application based on the resulting library, which I call mpeglib (or, when I'm feeling puffed-up, the MPEG Library).
The MPEG Library turned out to be quite popular -- for several years, John Cristy's popular ImageMagick suite used it as an optional add-on for decoding MPEG files; more recently, Adam Moss wrote a plug-in for the GIMP which uses mpeglib to read MPEG files. Unfortunately, hardly anyone out there seems to have noticed how cool glmpeg_play is; it has tons of features that I still haven't seen elsewhere: once the whole video stream is decoded into memory, it can play forwards or backwards, at varying speeds, can play two kinds of infinite loop (same direction forever, or "back and forth"), can zoom up as big as will fit on-screen, and has a "full-screen" mode that completely takes over the screen (great for those TV reporters who want to tape a demo for the evening news). Apparently, a portable, general-purpose library wins out over a special-purpose, platform-specific application!
The bad news is that I have little interest in digital video or multimedia, and less still in maintaining either mpeglib or glmpeg_play. They both need work, and I'm not going to be the one to do it. If you're interested in taking over development of these two worthy packages, please let me know!