15 May 2008

Converting video: Realmedia to DivX

I have a video which is encoded in rmvb. Realmedia (who they now?). I want to convert it to a divx file so that I can burn it on a DVD and watch it on my DivX-DVD player at home. This is what I tried to view it with ffmpeg:
# ffmpeg -i videofile.rmvb -vcodec mpeg4 out.mpg

FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al.
configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-libvorbis --enable-libtheora --enable-libogg --enable-libgsm --enable-dc1394 --disable-debug --enable-shared --prefix=/usr
libavutil version: 1d.49.3.0
libavcodec version: 1d.51.38.0
libavformat version: 1d.51.10.0
built on Mar 12 2008 14:31:53, gcc: 4.2.3 (Ubuntu 4.2.3-2ubuntu4)
[NULL @ 0xb7e086e8]Unsupported video codec
[NULL @ 0xb7e086e8]Unsupported video codec
Unsupported codec (id=72) for input stream #0.1
So that didn't work. FFmpeg doesnt seem to understand Realmedia. A bit of googling brought me to this command:
# mencoder videofile.rmvb -o outfile.avi -ovc xvid -xvidencopts fixed_quant=5 -oac mp3lame -lameopts abr:br=128

Opening video decoder: [realvid] RealVideo decoder
Error: /usr/lib/win32/drvc.so: cannot open shared object file: No such file or directory
Win32 LoadLibrary failed to load: drvc.so, /usr/lib/win32/drvc.so, /usr/local/lib/win32/drvc.so
Error loading dll
So that doesn't work either; looks like Im missing some DLLs. Abit more googling, and I am recommended to visit this page "MPlayer Codecs", which is a compilation of all the codec dll's for quite a few video formats. So I downloaded essential-20071007.tar.bz2 and windows-all-20071007.zip which was extracted into the /usr/bin/win32 directory as root.

After which, the mencoder command worked without a flaw in converting between Realmedia to DivX.

What joy, this multitude of proprietary file formats.

yk.