13/10/2007, 11:47 PM
Been converting a few DVDs manually recently, so I thought I'd just write up this guide for reference's sake. Also, because RonJon wanted me to write one up :P
Why manually rip a DVD?
In this guide, I'll be converting Fruits Basket Vol.3 to MKV, saving all audio tracks, subtitles and chapters.
Take note that this isn't really a "newbie guide to ripping DVDs".
Tools needed
Note that all tools mentioned here are completely free, with the exception of Goldwave.
Tools that you _may_ need:
Installation
This guide will assume you have the above installed. Additionally, you'll need to copy the DGDecode.dll file, which can be found in the DGIndex installation folder, into the plugins folder under the Avisynth installation directory. You will also need to copy TomsMoComp.dll file into the Avisynth plugin folder as well, if you plan to use TomsMoComp (recommended).
Note that this process may take up quite a bit of HDD space, depending on what you do.
Okay, to start:
Ripping the DVD
First, most DVDs have copy protection. Obviously these need to be stripped. Usually DVDDecrypter works fine - just pop the DVD in the drive, then go Mode menu » ISO » Read and dump the DVD as an ISO. Note that you may wish to skip this step, if DVDDecrypter can decrypt the DVD without issues, and rip the DVD in IFO mode (see following section).
DVDDecrypter may not always work, so you can try DVD Fab Decrypter instead, and then use FreeDVD on top of that.
Ripping the video
Anyways, now that you should have an ISO of the DVD (or if you skipped the above step, just rip straight from the DVD), wee'll need to rip the main PGC out. If you're dealing with an ISO, load Daemon Tools and mount the ISO. Next open DVDDecrypter, select the appropriate DVD drive from the list, and go Mode » IFO (don't start ripping yet).
If you want chapter info in your resulting video, you'll need to save the chapter info as well. If so, go Tools » Settings » IFO Mode (tab) and check Chapter Information - OGG, then click OK.
Okay, so now you're in IFO mode - select the PGC (or VOBs) which contains the main video. Usually, DVDDecrypter should have selected the main PGC for you. If there are multiple video angles, you can choose whether to keep both angles, or just rip one. In my Fruits Basket DVD, there's two angles, but since the only difference between the two are just some text, I'm only gonna be bothered to rip one angle.
If you are not sure whether you have selected the correct PGC, just leave it on whatever DVDDecrypter selected. You can double-check by looking at the length.
![[Image: untitledgd6.jpg]](http://img180.imageshack.us/img180/3702/untitledgd6.jpg)
In the above screenshot, 02:48:01 (2 hours, 48 minutes, 1 second) seems right.
Anyways, now just rip DVD in IFO mode. This process usually takes 2-40 minutes depending on various factors.
Demuxing
Now that you have a series of VOB files on your harddrive (if you got DVDDecrypter to dump as one large VOB file, rather than split into 1GB chunks, that's fine as well), open DGIndex, and add all the VOB files to DGIndex (make sure the order is right).
Now, go Audio » Output method » Demux All Tracks, then go File » Save Project.
Save the D2V file anywhere - note that you'll need around 250MB per AC3 track or about 750MB per DTS track that you rip. This process typically takes around 2-15 minutes.
After DGIndex does its stuff, you should have a .d2v file, and some .ac3 or .dts files - the latter is the extracted audio streams.
Subtitles
If you wish to get the subs, you have two options - either store them as subpictures or as text. DVDs store subtitles as subpictures, so this will be the easier option. Text will be, usually, a lot more problematic and may cause some loss of formatting etc, but saves a lot of space at the end, and are a lot more flexible.
Splitting (optional)
If you have an anime DVD like mine, and you want the video to be separated into episodes rather than one long video chunk, you'll need to do this.
No Splitting
This step only applies if you chose not to split the video in the above step.
Open Notepad, and copy the following into a new file:
Replace InputVideo.d2v with your d2v file obtained from DGIndex. If you aren't using TomsMoComp, remove the appropriate line from the above.
Now save the file as convV.avs in the same folder as your d2v file. This will be the AVS script for video.
Converting Video
You should now have AVS file(s). You can now choose between using MeGUI or converting through the command-line with x264. If you choose MeGUI, add the AVS file as the video input, then select the appropriate options and convert the video. I personally don't like MeGUI so I'll be converting with the command-line instead. Continue reading for instructions on how to convert using the command-line.
Open Notepad and copy the following:
I've highlighted the parts that you'll need to focus on. I'll explain them here.
Save this as conv.bat in the same folder containing everything. Now copy x264.exe into the same folder as well.
Finally, run conv.bat This will start the video convertion process and will probably take hours.
Converting Audio
This step will depend partially on what you've done above.
If you have 5.1 audio, well... I don't, so I won't be covering conversion of it yet. For now, you can easily just mux the AC3/DTS streams into the final MKV without conversion anyway. In fact, this is done fairly often in practice, it seems. If you do want to convert it, I suggest converting to 6 channel HE-AAC. This should be easy to do with MeGUI.
Now, for stereo audio:
Now, open up Goldwave. If you have .mka files at this point, open them in Goldwave. If you don't, open up the .ac3 or .dts file(s) in Goldwave.
Now wait for it to do it's thing, then go File » Save As. In the Save as type listbox, select Ogg (*.ogg), and for the Attributes listbox, select the one with "48000Hz 0.4q stereo" in it. Note that the "q" number determines the quality. A higher "q" means higher quality. Generally 0.4q produces CD transparent audio.
Now just save the file. This process will take some time.
Repeat this for each audio track you want.
Multiplexing
This is where you join up all your converted stuff into a single MKV file.
Open up MkvMergeGUI. Add you converted video file (should be in a .mkv file) and then your audio files (if you converted in the above step, they'll be .ogg, if not, they'll be .ac3 or .dts). Next, if you have any subtitles, just add them in.
At this point, you may wish to set the languages of your audio streams (just select the audio stream to change, and select the language from the listbox below), video streams and subtitle streams.
After all that, if you decided to keep chapter info, click the Global tab, and add the chapter file (.txt) in the appropriate location.
Finally, make sure you go File » Set output file to choose where you want to save the final MKV file, before going Muxing » Start muxing.
The muxing operation should only take a few seconds to a few minutes. After it's done, open up the MKV to make sure it's exactly what you wanted. If you split the video, you'll have to repeat this for every MKV you want in the end.
So now you've successfully ripped and converted your DVD :) (hopefully)
Why manually rip a DVD?
- Gives you the most options
- If there are problems - it allows you to easily identify what problems there are
- Probably the only way to get _everything_ off a DVD.
In this guide, I'll be converting Fruits Basket Vol.3 to MKV, saving all audio tracks, subtitles and chapters.
Take note that this isn't really a "newbie guide to ripping DVDs".
Tools needed
Note that all tools mentioned here are completely free, with the exception of Goldwave.
- DVDDecrypter
- DGIndex (aka DGMPGDec)
- MKVMergeGUI (aka MKVToolnix)
- Avisynth
- TomsMoComp AVS plugin (really optional, but I highly recommend it)
- Goldwave (this application isn't technically free, but trial lasts a long time; you may use another sound editor if you wish - I primarily use this one because of it's ability to open files via DirectShow)
- x264 command-line app or MeGUI (make sure you get the x264.exe file [Download rev680] or the MeGUI package)
Tools that you _may_ need:
- DVD Fab Decrypter (if DVDDecrypter doesn't work)
- FreeDVD (if the DVD has extra copy protection)
- Daemon Tools (if you have an ISO)
- VobSub (if you want to rip subs to subpicture format)
- SubRip (if you want to rip subs to a text format)
- K-Lite Codec Pack (if you don't already have a decent codec pack installed)
- azid (if you don't use Goldwave)
- oggenc2 or Nero's AAC encoder (for various situations)
Installation
This guide will assume you have the above installed. Additionally, you'll need to copy the DGDecode.dll file, which can be found in the DGIndex installation folder, into the plugins folder under the Avisynth installation directory. You will also need to copy TomsMoComp.dll file into the Avisynth plugin folder as well, if you plan to use TomsMoComp (recommended).
Note that this process may take up quite a bit of HDD space, depending on what you do.
Okay, to start:
Ripping the DVD
![[Image: dvddwh6.th.jpg]](http://img90.imageshack.us/img90/4647/dvddwh6.th.jpg)
DVDDecrypter may not always work, so you can try DVD Fab Decrypter instead, and then use FreeDVD on top of that.
Ripping the video
Anyways, now that you should have an ISO of the DVD (or if you skipped the above step, just rip straight from the DVD), wee'll need to rip the main PGC out. If you're dealing with an ISO, load Daemon Tools and mount the ISO. Next open DVDDecrypter, select the appropriate DVD drive from the list, and go Mode » IFO (don't start ripping yet).
![[Image: dvddsubnu1.th.jpg]](http://img90.imageshack.us/img90/6416/dvddsubnu1.th.jpg)
If you are not sure whether you have selected the correct PGC, just leave it on whatever DVDDecrypter selected. You can double-check by looking at the length.
![[Image: untitledgd6.jpg]](http://img180.imageshack.us/img180/3702/untitledgd6.jpg)
In the above screenshot, 02:48:01 (2 hours, 48 minutes, 1 second) seems right.
Anyways, now just rip DVD in IFO mode. This process usually takes 2-40 minutes depending on various factors.
Demuxing
![[Image: dgi1mx2.th.jpg]](http://img90.imageshack.us/img90/9310/dgi1mx2.th.jpg)
![[Image: dgi2hm1.th.jpg]](http://img90.imageshack.us/img90/8764/dgi2hm1.th.jpg)
Save the D2V file anywhere - note that you'll need around 250MB per AC3 track or about 750MB per DTS track that you rip. This process typically takes around 2-15 minutes.
After DGIndex does its stuff, you should have a .d2v file, and some .ac3 or .dts files - the latter is the extracted audio streams.
Subtitles
If you wish to get the subs, you have two options - either store them as subpictures or as text. DVDs store subtitles as subpictures, so this will be the easier option. Text will be, usually, a lot more problematic and may cause some loss of formatting etc, but saves a lot of space at the end, and are a lot more flexible.
Spoiler for How to do it:
Ripping as subpictures
After installing VobSub, open VobSub Configure. Then click the Open button and from the Files of type dropdown list, select the 2nd option (Ifo/Vob). Select the IFO file which you obtained from DVDDecrypter. It will now ask you where to save the demuxed subpictures. Store them in a folder of your choice. Should only take around 20-30MB. After clicking OK, you'll be brought to another dialog - the defaults should be fine so click OK again. Now VobSub will demux and convert the subtitles for you :P After it's done, just close VobSub.
Ripping as text
Open SubRip. Go File » Open VOBs. Click Open IFO and select the IFO file obtained from DVDDecrypter. In the Action section, choose SubPictures to Text via OCR. Then click the little blue icon button below the Action frame - a new dialog should pop up. In the left hand side, select SubRip (*.srt) then I'll leave it up to you what to do in the right hand side (just don't change the Subtitle Index Offset value). Click Convert to the Format, then Start.
Once it starts, you'll be asked to tell the program what each character is... This will take a while...
Usually it should work well. I've noticed that at times it may group 2 characters together - not an issue - just enter in the two characters :P Also, it tends to confuse "I" with "l".
After the conversion, focus your attention on the 2nd smaller window with a black background and white text (should be titled Subtitles | NewFile.srt). You'll probably want to go Correction » Post OCR Correction, then just perform any fixes necessary (yay! they have the "I" and "l" fix!). If you'll be splitting the video (see next section), you should do so here. Then just save the file as a .SRT, or if you split, save an SRT for each split part.
After installing VobSub, open VobSub Configure. Then click the Open button and from the Files of type dropdown list, select the 2nd option (Ifo/Vob). Select the IFO file which you obtained from DVDDecrypter. It will now ask you where to save the demuxed subpictures. Store them in a folder of your choice. Should only take around 20-30MB. After clicking OK, you'll be brought to another dialog - the defaults should be fine so click OK again. Now VobSub will demux and convert the subtitles for you :P After it's done, just close VobSub.
Ripping as text
![[Image: subriptx0.th.jpg]](http://img90.imageshack.us/img90/6237/subriptx0.th.jpg)
Once it starts, you'll be asked to tell the program what each character is... This will take a while...
Usually it should work well. I've noticed that at times it may group 2 characters together - not an issue - just enter in the two characters :P Also, it tends to confuse "I" with "l".
After the conversion, focus your attention on the 2nd smaller window with a black background and white text (should be titled Subtitles | NewFile.srt). You'll probably want to go Correction » Post OCR Correction, then just perform any fixes necessary (yay! they have the "I" and "l" fix!). If you'll be splitting the video (see next section), you should do so here. Then just save the file as a .SRT, or if you split, save an SRT for each split part.
Splitting (optional)
If you have an anime DVD like mine, and you want the video to be separated into episodes rather than one long video chunk, you'll need to do this.
Spoiler for How to do it:
This can be annoying. I decided to simplify this process up a little by making my own little program. It can be found here:
[attachment=868]
Open the program, then load the OGG chapter file. You should see something like this:
![[Image: splitqf1.jpg]](http://img145.imageshack.us/img145/1295/splitqf1.jpg)
Now if you look at the chapter list, you'll notice that the 1st episode starts at chapter 1, then you should be able to tell that chapter 2 is where the actual episode starts (chapter 1 would be the opening sequence). Chapter 3 is the intermission, chapter 4 is the start of the ending sequence, then chapter 5 is the start of the 2nd episode's preview. If you are unsure what is what, check the DVD's chapters and make sure you know what each chapter refers to.
So back to my Fruits Basket DVD, you should be able to tell that there are 5 chapters to an episode, so in the "Split every" textbox, enter the number 5 and click the button next to it.
Next, wee'll need to look at the AVS template textbox. For video, I'll use the following template:
Replace InputVideo.d2v with the name of the d2v file obtained from DGIndex. If you aren't using TomsMoComp, remove the appropriate line from the above.
Now change the AVS File Prefix to Video. Finally, hit the Split button. The app should give you an AVS and TXT file for each episode.
Now, if the source audio is stereo (only 2 channels) do the following. Note that you'll need to redo this for each audio track that you want in the final video. Also note that you should replace InputAudio.ac3 with the AC3 or DTS file containing the audio data.
For stereo input, change the AVS Template to the following:
Then click Split again.
Now, if you have subs, you'll need to split them as well... For subpictures, open VobSub Cutter, and just cut the subs with that. If you want text subtitles, you should have split them in the above step.
[attachment=868]
Open the program, then load the OGG chapter file. You should see something like this:
![[Image: splitqf1.jpg]](http://img145.imageshack.us/img145/1295/splitqf1.jpg)
Now if you look at the chapter list, you'll notice that the 1st episode starts at chapter 1, then you should be able to tell that chapter 2 is where the actual episode starts (chapter 1 would be the opening sequence). Chapter 3 is the intermission, chapter 4 is the start of the ending sequence, then chapter 5 is the start of the 2nd episode's preview. If you are unsure what is what, check the DVD's chapters and make sure you know what each chapter refers to.
So back to my Fruits Basket DVD, you should be able to tell that there are 5 chapters to an episode, so in the "Split every" textbox, enter the number 5 and click the button next to it.
Next, wee'll need to look at the AVS template textbox. For video, I'll use the following template:
Replace InputVideo.d2v with the name of the d2v file obtained from DGIndex. If you aren't using TomsMoComp, remove the appropriate line from the above.
Now change the AVS File Prefix to Video. Finally, hit the Split button. The app should give you an AVS and TXT file for each episode.
Now, if the source audio is stereo (only 2 channels) do the following. Note that you'll need to redo this for each audio track that you want in the final video. Also note that you should replace InputAudio.ac3 with the AC3 or DTS file containing the audio data.
For stereo input, change the AVS Template to the following:
Then click Split again.
Now, if you have subs, you'll need to split them as well... For subpictures, open VobSub Cutter, and just cut the subs with that. If you want text subtitles, you should have split them in the above step.
No Splitting
This step only applies if you chose not to split the video in the above step.
Open Notepad, and copy the following into a new file:
Replace InputVideo.d2v with your d2v file obtained from DGIndex. If you aren't using TomsMoComp, remove the appropriate line from the above.
Now save the file as convV.avs in the same folder as your d2v file. This will be the AVS script for video.
Converting Video
You should now have AVS file(s). You can now choose between using MeGUI or converting through the command-line with x264. If you choose MeGUI, add the AVS file as the video input, then select the appropriate options and convert the video. I personally don't like MeGUI so I'll be converting with the command-line instead. Continue reading for instructions on how to convert using the command-line.
Open Notepad and copy the following:
I've highlighted the parts that you'll need to focus on. I'll explain them here.
- -q 20
This option controls the quality of the outputted video. This value ranges from 0 (highest quality) to 51 (very bad quality). Generally a value of 16-20 gives very high quality video, suitable for DVD backups. For average quality, 24-26 should do.
- --sar 16:15
This controls the aspect ratio (AR) of each pixel. My source video happens to have a resolution of 720x576 (AR by dimensions = 5:4) but the actual video's AR is 4:3. So 5/4 × 16/15 = 4/3 « that's where the "16:15" comes from.
You'll probably need to change this depending on the resolution and the final AR you want.
- -o FB.mkv
Specifies the output video file. Although it carries a .mkv extension, this will not be the final MKV file. In the above, ]FB.mkv is the output file.
- Video01.avs
The input AVS file obtained above.
Spoiler for If you split the video into multiple AVS files:
You'll need to put the first AVS here, then copy and paste the entire command given above on a new line for each AVS file. For my Fruits Basket conversion, my Notepad looks like this:
Finally, run conv.bat This will start the video convertion process and will probably take hours.
Converting Audio
This step will depend partially on what you've done above.
If you have 5.1 audio, well... I don't, so I won't be covering conversion of it yet. For now, you can easily just mux the AC3/DTS streams into the final MKV without conversion anyway. In fact, this is done fairly often in practice, it seems. If you do want to convert it, I suggest converting to 6 channel HE-AAC. This should be easy to do with MeGUI.
Now, for stereo audio:
Spoiler for If you split the audio in a previous step:
Open up MkvMergeGUI, and add the AC3/DTS track to it. Now save this as audio.mka If you want multiple audio tracks, go File » New and repeat this for each track (saving as a different .mka file each time)
Now wait for it to do it's thing, then go File » Save As. In the Save as type listbox, select Ogg (*.ogg), and for the Attributes listbox, select the one with "48000Hz 0.4q stereo" in it. Note that the "q" number determines the quality. A higher "q" means higher quality. Generally 0.4q produces CD transparent audio.
Now just save the file. This process will take some time.
Repeat this for each audio track you want.
Multiplexing
This is where you join up all your converted stuff into a single MKV file.
Open up MkvMergeGUI. Add you converted video file (should be in a .mkv file) and then your audio files (if you converted in the above step, they'll be .ogg, if not, they'll be .ac3 or .dts). Next, if you have any subtitles, just add them in.
At this point, you may wish to set the languages of your audio streams (just select the audio stream to change, and select the language from the listbox below), video streams and subtitle streams.
After all that, if you decided to keep chapter info, click the Global tab, and add the chapter file (.txt) in the appropriate location.
Finally, make sure you go File » Set output file to choose where you want to save the final MKV file, before going Muxing » Start muxing.
The muxing operation should only take a few seconds to a few minutes. After it's done, open up the MKV to make sure it's exactly what you wanted. If you split the video, you'll have to repeat this for every MKV you want in the end.
So now you've successfully ripped and converted your DVD :) (hopefully)