X-Git-Url: http://git.pippins.net/embedvideo/.git/static/git-logo.png?a=blobdiff_plain;f=rip_dvd;h=3e6d5059b9cf910df259fccf5ce72413c944993d;hb=a0392e5f7d75539a0a6831d88fda15c821507dae;hp=57297544d5b3084fa0e0cb1ba9449fd2d427252b;hpb=26c9a0465a97c490b541f0379d25a4e940e32b0f;p=rip_dvd%2F.git diff --git a/rip_dvd b/rip_dvd index 5729754..3e6d505 100755 --- a/rip_dvd +++ b/rip_dvd @@ -15,58 +15,27 @@ # Known Issues/Limitations: # - Mirror mode is always done in ISO mode # -# Package Dependencies: -# lsdvd dvdauthor gddrescue dvdbackup makexml tovid mencoder vlc mplayer genisoimage +# Package Dependencies (apt-get install these for example): +# lsdvd dvdauthor gddrescue dvdbackup tovid mencoder mplayer genisoimage libdvdcss2 +# +# Specific Executable (program) Dependencies (must be found in $PATH): +# volname makexml lsdvd dvdauthor gddrescue dvdbackup mencoder mplayer mkisofs # # Optional Dependencies: # lookup imdb info/posters for mythvideo: http://www.mythtv.org/wiki/Fill_mythvideo_metadata.pl # -############################################### -# Local Machine Settings - EDIT THIS SECTION - -# Specify the device path to the DVD drive -dev=/dev/dvd2 - -# Specify the path to the log directory -logdir=/var/log/ripdvd - -# Specify the path to the tmp rip directory -tmpdir=/myth/video/DVDs/.ripdvd - -# Specify the email address to send job notifications to -mailto=ajp@pippins.net - -# Setup the path to the tools needed by this ripper -PATH=/etc/mythtv/bin:/usr/local/bin:/usr/sbin:/sbin:/usr/bin:.:$PATH - -# Use mplayer dumpstream to create the main VOB file -# If set to 0, cat and other utils will be used to make it instead. -# Using mplayer dumpstream is by far the best way to create the main VOB file -# The only thing this doesn't work for are DVDs with the 99 title copy protection. -# The script will autodetect these types of disks, and change this to 0 if necessary. -# If this is set to 0, other methods will be employed to get the DVD VOB dump. -use_mplayer_dumpstream=1 - -# 2-channel AVI encoding audio bit rate -audio_bitrate=224 - -# If set to 1, this script will call another script to fill in the mythvideo metadata -# If you don't use mythtv, set this option to 0. If you use mythtv, and have downloaded -# the fill_mythvideo_metadata.pl script shown above, you can leave this option set to 1. -fill_mythvideo_metadata=1 - -# If the 99 titleset copy protection scheme is detected, trust the autodetection or abort. -# The autodetection may work, but it probably won't in this case. Set to 0 by default. -# Override to 1 if you want the script to wing it, and hope it picks the right feature title. -# Otherwise, you will need to rerun the script providing the feature title with the -t option. -trust_feature_title_autodetect_when_uncertain=0 - -# specify the number of threads that mencoder should use when encoding the video (AVI mode) -# an optimal setting for this should be the number of cores you have times 2 -# note: you have to have an mplayer version that has been compiled with multi thread support. -# if you don't, this will have no effect, but won't hurt anything to have it set otherwise. -mencoder_threads=8 +############################################################################## +# Local Machine Settings: +# Sources both the "default" conf file tracked by GIT (rip_dvd.conf.dist) +# and the local conf file created by each local machine (rip_dvd.conf) +# Copy the rip_dvd.conf.dist file to rip_dvd.conf and edit the later. +# This will allow you to override all the default values to meet your needs +# in a way that won't get clobbered when you pull updates from my GIT repo. +############################################################################## +config="${0%/*}/rip_dvd.conf" +[ -e "${config}.dist" ] && . ${config}.dist +[ -e "${config}" ] && . ${config} ############################################### # Command line processing @@ -235,6 +204,12 @@ else ripdvd=0 fi +# remove bad characters from the dvdname +dvdname=${dvdname%.} # remove trailing '.' character + +# make a "safe" dvdname (remove special characters) +safedvdname=`basename "$dvdname" | sed 's/[ !&*\\$?]/_/g'` + # Make sure we have a non-empty dvdname if [ -z "$dvdname" ]; then echo "-E- unable to determine dvdname" @@ -246,9 +221,6 @@ if [ -z "$vobfile" ]; then vobfile="$dest/$dvdname.VOB" fi -# make a "safe" dvdname (remove special characters) -safedvdname=`basename "$dvdname" | sed 's/[ !&*\\$?]/_/g'` - # set up some variables to hold various logfiles logfile="$logdir/$dvdname.log" passlogfile="$tmpdir/$safedvdname.log" @@ -715,6 +687,7 @@ function check_for_mplayer_dumpstream_incompatibility { if [ $trust_feature_title_autodetect_when_uncertain -eq 0 ]; then echo "-E- Unable to determine the feature title due to the 99 title copy protection scheme" | tee -a "$logfile" echo " You will need to determine this yourself and rerun the script with the -t option" | tee -a "$logfile" + echo " You can google this DVD to find out what it's feature title is, or you can play it in a conventional DVD player to find it." | tee -a "$logfile" invalid_feature_title=1 else echo " Falling back to non mplayer dumpstream methods to copy the DVD" | tee -a "$logfile"