Gentoo Archives: gentoo-user

From: Richard Marza <richardmarzan@×××××××××.net>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Bash Script that wraps Mplayer/Mencoder.
Date: Fri, 25 Sep 2009 10:17:51
Message-Id: 2548BB89D7864CFDB19AA82445E563C5@RichardPC
1 I have a script currently called rip that rips DVDs to H.264 using x264 with mencoder. It always does 2 passes and runs 2 threads(uses two cores). It has many lines but I'm sure if we work together we can shorten the number of lines and add more functionality. Uhm...for now, it does what it is supposed to do. It could use a little bit more functionality but it is user friendly once you have the right tools installed. It uses mplayers crop-detection feature to crop black bands out of the video. It requires libdvdread, lsdvd, mencoder/mplayer with x264, sed and of course bash. Here is the syntax below:
2
3 ./rip.s dvd_device bitrate movie_name audio_id title
4
5 Examples:
6 ./rip.sh /dev/sr0 1200 Movie_Name 128 1
7 This will rip title 1 from device /dev/sr0 and place the video files into MovieName directory. The resulting file will be Movie_Name.avi.
8
9 or if you have a range of titles to rip you can also specify this like so:
10
11 ./rip.sh /dev/sr0 1200 Movie_Name 128 1-3
12
13 or if you don't know which title... It'll choose the longest title for you with the trailing option below. Just change the title field to auto
14
15 ./rip.sh /dev/sr0 1200 Movie_Name 128 auto
16
17 If you're not sure what the options are just run the script without any options. It will tell you if you can't remember or are not sure.
18
19 I created the script because Acidrip ceased to work after a while. It no longer does what it used to do. Maybe it'll work on older distributions. In summary, Acidrip has not been updated to use the latest libraries. My script has much less of the functionality that Acidrip once had but it gets the job done. If anyone is interested please let me know and I will most definitely post it here. I look forward to porting this to python one day and calling it Acidripy using pygtk. Thank you for reading. I look forward to hearing from you guys.

Replies

Subject Author
[gentoo-user] Re: Bash Script that wraps Mplayer/Mencoder. Doug Hunley <doug@×××××××××××××.net>