However, if, like me, you want to be able to watch DVD's on your little Pentium II laptop (IBM Thinkpad 600) every once in a while, then you need a quick way to rip movies from DVD's and shrink them down. The attached script is designed to do just that.
Unlike the rest of the world, Puppy Linux people tend to think more like I do, so someone may have already come up with another way to do this. If so, please chime in: I'd love to find ways to make my movie ripping easier.
I looked at pdvdrsab, but it ripped the movies in a format that I couldn't do a whole lot with if I wanted to edit them. Oh, and I had difficulty using -vob (it insisted I used -vf, which worked well. ) I also found pdvdrsab failed to rip for me much more frequently than mencoder did. Don't get me wrong; I still use pdvdrsab, but this script has helped make life easier.
I could (and sometimes do) rip movies using VLC media player, but that ripped them to an mpg format then I had to shrink them, etc. No matter the variations I used, VLC just didn't suit my needs.
So, after playing around with ffmpeg and mencoder, I came up with a little script that uses both of them and rips directly from the DVD, creates an .avi file (that can be played in the dreaded Windows Media Player if necessary and easily edited in Avidemux), and then uses mencoder to shrink down the .avi file, thus creating a total of two .avi files, one much smaller than the other.
What to do: if you want to run the script, this is the process I find easiest:
1. Initially, copy the script into geany (or whatever text editor you use), save it in your Movies folder, then, using rox-file manager, right click the script, changing the preferrences to make it executable ( you can do this other ways, but I find it is ridiculously easy in Puppy using rox to make scripts active, much easier than chmod'ing things).
2. Put in the dvd you want to rip in your dvd player.
3. Use your terminal and change directories to your movie directory.
4. Determine which chapter title on the dvd contains the actual movie (there are several ways to do this. You can search by each chapter using VLC media player to find the correct one if you want. I find the easiest and most successful way, most of the time, is to run pdvdrsab if you have it installed, tell it you are going to rip the dvd, then see which chapter it selects as the largest one. I then cancel pdvdrsab and run this script. Usually the correct title is 1).
5. Use your text editor (geany) to open "letitrip" and change the movie name and title number as needed (please read what few notes I've put on the script if you need any clarity). Then save it and close it.
6. In terminal type ./letitrip and the script will run. Of course, if you've saved the script under a different name, run it via that name.
The end result is two seperate movie files, both avi's, one much smaller than the other. Using gmplayer (a whole thread or two that can easily be found by searching this forum) I can play these smaller avi files with ease on the PII laptop.
If you don't like something about the script, then feel free to change, enhance, whatever. I just though: hey, it helps me, maybe it will help someone else.
*note: the line that contains the mencoder instructions is one line. The line that contains the ffmpeg instructions is one line.
Code: Select all
#!/bin/bash
###############################################
# LetItRip!
# This little script will rip from a dvd to a
# medium sized avi file then shrink it to a smaller
# avi file. The final result will be two different
# sized avi files.
###############################################
### here you can name the movie. Use dashes for spaces leaving
### nothing blank.
mname=example-movie
### here you can number which block on the dvd the movie is contained,
### usually 1.
title=1
mencoder -aspect 4:3 dvd://$title -ovc lavc -lavcopts vcodec=mpeg4:vhq:vbitrate=694 -vf scale=640:480 -oac mp3lame -lameopts br=128:vol=7 -o $mname.avi
ffmpeg -i $mname.avi -f avi -s 232x158 -r 29.97 -ab 128 -ar 48000 -ac 2 -acodec libmp3lame -vcodec msmpeg4v2 $mname-small.avi