A video library: ripping with mencoder, acidrip, transcode and DVD::RIP


I've got a mythtv server at home that I've slowly been filling with movies. I've been buying the movies then ripping them to disk with dvd::RIP. The main use for this is in my office where I watch (actually just listen) to a movie on one workspace while I work on software or work on my book or articles on another. I hope to eventually hook a MiniMyth client up downstairs on the big TV. Anyway, the ripping and encoding with transcode/DVD::RIP worked quite well for the past 6 months, running on a fedora Core 2 box. Then I did a yum update. Now DVD::RIP refuses to encode the VOBs it rips.

I'm not sure what the problem is. It probably has something to do with the ffmpeg being updated or maybe transcode itself, which was rev'd to version 1.0 this summer. In anycase, I never could get it working again.

So I went hunting for an alternative. There are quite a few options but the one that installed the easiest and offers a complete rip/encode process is AcidRip. This tool is a front end to the mencoder application that is part of the mplayer package. Mencoder can be used to rip from the DVD and then encode on the fly to avi. This allows me to keep 1.4MB versions of the movie on disk, so I can get a lot of movies on the server.

The only problem I've run into using this tool is that the audio is out of sync with the video by a hair. I did a quick check on the AcidRip Forums on SourceForge and found that this is apparently a known problem with mplayer (though the mplayer developers are said not to admit it's a problem) and not with the encoding. You can get around the problem by using xine and hitting “m” until the delay is about 0.32. I haven't checked on this yet but I think I can configure MythTV to play certain movies with specific players and therefore use specific command line args so getting the audio/video in sync on a per-movie basis should be possible. In this way I can fix the sync problems with movies encoded with mencoder while not having to worry about it for movies I encoded with transcode, which doesn't appear to have the sync problem.

Since this is a sync delay problem, you can specify -autosync value with mplayer to force a sync. The best I could do was about -autosync 255 but that seems high. Xine doesn't appear to have a command line option to fix this so that's not an option with MythTV. I haven't tried the mencoder option -ofps 23.976 yet but that would be the next thing to try. And the last option on the Forums that says to use lavc instead of mp3 doesn't help since I was already using lavc. However, I did switch to ac3 instead of mp3 in the acodec option. That test is running now. I'll post later if it worked.

Update: mplayer didn't work well, even with the autosync setting. I switched to Xine for the movies encoded by mencoder and just have to deal with manually setting the sync using the “m” option while the movie is running. I just set it to 0.32 as an offset (hit “m” several times). The tests with -ofps and using ac3 have not completed yet.

Anyway, I just wanted to note this little workaround for myself when I get around to configuring these movies manually under MythTV.