True or False - Is it possible to convert a VOB on DVD to MPEG4 w/NO quality loss?

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
I'm wondering if it's possible to convert a VOB on DVD to MPEG4 or anything else my HTPC can play w/NO quality loss? My interest is saving space to all the rips I have on hard drives.
 

Modelworks

Lifer
Feb 22, 2007
16,240
7
76
It depends on how absolute the quality loss is. Can you convert it with 99% quality, yes. 100% never
 

mmntech

Lifer
Sep 20, 2007
17,501
12
0
You can achieve transparency. That's where it looks close to the point where it's difficult to tell. About 3 to 4mbps works. There will always be some quality loss though since all codecs throw away information in the process.
 

darkxshade

Lifer
Mar 31, 2001
13,749
6
81
Quality without substance is the bane of every picture. Without mousetraps, vegetables cannot grow.
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
True. But you won't save any space. MPEG-4 supports a lossless encoding option, however, it will used way more bits then the raw MPEG-2 already takes up.

If you are shooting for a smaller file, then there WILL be quality loss, there is no way around it. However, that loss can be very minimal. My recommendation is using x264 with CRF mode. a setting of 18 on veryslow or slow is considered by most to be transparent and should result in a smaller file then your MPEG2 encoded video.
 

Slick5150

Diamond Member
Nov 10, 2001
8,760
3
81
When going from one lossy format (DVD MPEG-2) to another (MPEG-4), there will always be SOME loss of quality. The question is whether it is discernible or not, and if done right, i'd imagine you'd at have a hard time telling the difference between the two.
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
It depends on how absolute the quality loss is. Can you convert it with 99% quality, yes. 100% never

You can achieve transparency. That's where it looks close to the point where it's difficult to tell. About 3 to 4mbps works. There will always be some quality loss though since all codecs throw away information in the process.

As I said in my post above, the Mpeg-4 standard supports a lossless encoding mode. However, the output files will be bigger then the input.
 

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
True. But you won't save any space. MPEG-4 supports a lossless encoding option, however, it will used way more bits then the raw MPEG-2 already takes up.

If you are shooting for a smaller file, then there WILL be quality loss, there is no way around it. However, that loss can be very minimal. My recommendation is using x264 with CRF mode. a setting of 18 on veryslow or slow is considered by most to be transparent and should result in a smaller file then your MPEG2 encoded video.

Thanks. How much smaller? For example "a river runs through it" folder is 5.1GB right now.

PS that last stuff is greek to me. What app are you talking about? I use DVD shrink.
 

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
As I said in my post above, the Mpeg-4 standard supports a lossless encoding mode. However, the output files will be bigger then the input.

That does not make any sense. I thought the whole idea with MPEG4 was we have better processors now so we can do more math and thus make smaller file sizes than mpeg2
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
Thanks. How much smaller? For example "a river runs through it" folder is 5.1GB right now.

PS that last stuff is greek to me. What app are you talking about? I use DVD shrink.

x264 is an H.264 encoder (MPEG-4 AVC standard). It is currently one of the best encoders available, thus will give you the most quality/bitrate.

With it, you have two options, you can have a known filesize and a unknown quality or a known quality an unknown file size, unfortunately there isn't much way (short of a guess) to predict the exact output file size for a given quality, this is due to the fact that every video is different. Generally, unless you are targeting a CD or something, this is fine, you'd be surprised at how small the files can be (I've gotten a 30min clip from 1gb to 100mb with x264 It looked great as well).

CRF mode in x264 is the "unknown filesize, known quality(ish) option" with it, you get approximately the same quality at a given CRF number. It is up to your personal tastes what number is good, I've gone as high as 24 and as low as 16 before (which results in vastly different file sizes, Bigger number = worse quality).

DVD Shrink is NOT a good option as it encodes an MPEG2 -> Mpeg2. I've never had good experiences with it either, every time I've seen noticeable corruption.

My toolchain looks something like this. DVD decrypter (handles a good deal of movies, struggles with the newer ones) or DVDFab(free, handles most movies, though, I don't like the UI, it also doesn't support as many options as DVD Decrypter) to get the raw VOBs off the disk, I'll generally use just a straight Command line to do the encoding, however, I've had some good luck with MeGui. I've also heard good things about starx rip. They'll step you through the transcoding. After that, you combine the files and Viola, you have an MPEG4 standard video ready to be played.

More info can be found at forum.doom9.org Specifically in the Mpeg-4 AVC sub-forum. One of the developers of x264 is quite active there, and fairly helpful (dark shikira)
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
That does not make any sense. I thought the whole idea with MPEG4 was we have better processors now so we can do more math and thus make smaller file sizes than mpeg2

Lossless video takes up space, there is no way around it. To get an exact recreation of a video, the encoder has to decode each frame of the video (from MPEG 2) and re-encode it to an MPEG-4 standard video. It cannot use anything from the previous MPEG2 encode (except for the decoded video of course) so it is left to create an exact pixel-per-pixel representation of the video by throwing tones of bits at it.

MPEG-2 Is a lossy (not perfect reproduction) format. A lossless format just can't compare with a lossy format in file size, there is no way.

MPEG4 is capable of getting smaller files/with higher quality then MPEG2, however, you still lose quality when you do a lossy encode. There is no way around that. lossless and lossy encodes are two separate beasts. Comparing a lossless standard to a lossy standard just doesn't work.

Its like comparing an MP3 with a FLAC file. FLACs are pretty much always bigger, however, MP3 has an older standard? Why is that? Because the FLAC format is lossless. It provides perfect reproduction of the sound that was ran through it, but that reproduction comes at the cost of a higher bitrate. Even though it is doing more math then the MP3, it still has a higher bitrate associated with it.

Most people want transparency, not perfect reproduction. They are very different things (JPEG vs PNG). When you say no quality loss, that means to me "perfect reproduction", and that means a lossless encode. Since the video is already encoded lossy, a lossless encoding will almost always result in a large filesize then the file it was encoded from. Now, if you want a transparent encode, then you can easily manage a much smaller file with minimal degradation of quality.
 
Last edited:

Raduque

Lifer
Aug 22, 2004
13,140
138
106
Thanks. How much smaller? For example "a river runs through it" folder is 5.1GB right now.

PS that last stuff is greek to me. What app are you talking about? I use DVD shrink.

I have an x264 of Contact that's about 2gb. It looks indistinguishable from my DVD.
 

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
You're my new hero cogman.. Thanks. I'll take your cues and get x264 and use settings advised. I tried handbrake on "high profile" and a few other settings in the advanced tab and video looked poor and took about 6 hours for video in question. trimmed form 5.1GB to 3.2 only.

For ripping I use anydvd.
 
Last edited:

Modelworks

Lifer
Feb 22, 2007
16,240
7
76
As I said in my post above, the Mpeg-4 standard supports a lossless encoding mode. However, the output files will be bigger then the input.

There will still be loss because of the way the matrices are used to interpret the data from what the decoder output to what the encoder inputs. Studios keep film stored as one TGA file for each frame of film for that reason rather than just converting it to a lossless format .

It is also a good way to back up DVD collections at home but it takes a ton of space.
 

Modelworks

Lifer
Feb 22, 2007
16,240
7
76
I have an x264 of Contact that's about 2gb. It looks indistinguishable from my DVD.

If done right compression can have amazing quality. Most people don't even notice compression artifacts. A good way to see them though is to pause the playback and turn brightness all the way up , show up especially in scenes with lots of detail like rain.
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
There will still be loss because of the way the matrices are used to interpret the data from what the decoder output to what the encoder inputs. Studios keep film stored as one TGA file for each frame of film for that reason rather than just converting it to a lossless format .

It is also a good way to back up DVD collections at home but it takes a ton of space.

I'm pretty sure the reason they stick with TGA files is for easier editability and not really anything to do with storage concerns. Plus, a bit lost in a TGA file means nothing compared to a bit lost in a losslessly compressed version of that file. For a lossless compression scheme the reproduced output is going to be the same as the input, the only way there will be a difference is if they applied some sort of pre/post filter to the file.
 

Modelworks

Lifer
Feb 22, 2007
16,240
7
76
I'm pretty sure the reason they stick with TGA files is for easier editability and not really anything to do with storage concerns. Plus, a bit lost in a TGA file means nothing compared to a bit lost in a losslessly compressed version of that file. For a lossless compression scheme the reproduced output is going to be the same as the input, the only way there will be a difference is if they applied some sort of pre/post filter to the file.

Part of the reason for using TGA is it has been used for film work for at least 15 years so everyone is familiar with it. I still get work delivered on drives with 15,000 tga files for the short clips I need. Another reason is the likelihood that the format will become obsolete or unreadable is very slim because it is so easy to read.
 

mmntech

Lifer
Sep 20, 2007
17,501
12
0
Given how cheap external hard drives are, it might be better to go that route and just keep the raw MPEG2 rips. You can store approximately 125 DVD movies on a 1TB drive. This is the route I would go if you don't want quality loss.

A NAS server is another option. This is what I have for my streaming setup. I took an old laptop and an external USB HDD running PS3 Media Server. Works great.
 

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
Given how cheap external hard drives are, it might be better to go that route and just keep the raw MPEG2 rips. You can store approximately 125 DVD movies on a 1TB drive. This is the route I would go if you don't want quality loss.

A NAS server is another option. This is what I have for my streaming setup. I took an old laptop and an external USB HDD running PS3 Media Server. Works great.

That's what I have been doing but it's at end...I have a synology 1.5 TB x 4 in RAID 5 for about 4.53 TB storage. It's full and I have 7 seasons of TV shows waiting to RIP.

Cog I just got home from running and about to try your method. Thanks again.
 
Last edited:

alyarb

Platinum Member
Jan 25, 2009
2,425
0
76
You're my new hero cogman.. Thanks. I'll take your cues and get x264 and use settings advised. I tried handbrake on "high profile" and a few other settings in the advanced tab and video looked poor and took about 6 hours for video in question. trimmed form 5.1GB to 3.2 only.

For ripping I use anydvd.

how you rip the files doesn't really matter. experiment with RF numbers in handbrake (under the video tab -> constant quality) and you will find something that is both transparent and much lower bitrate than MPEG2. do it on your i7. yes, extreme quality encoding takes time.
 

Zebo

Elite Member
Jul 29, 2001
39,398
19
81
how you rip the files doesn't really matter. experiment with RF numbers in handbrake (under the video tab -> constant quality) and you will find something that is both transparent and much lower bitrate than MPEG2. do it on your i7. yes, extreme quality encoding takes time.

Did use i7

Following were changes from High Profile Preset built in to Zebo's custom preset

-Video tab Constant Quality 76.96%

-Subtitles tab - Burn in forced

-Advanced
Direct prediction - automatic
Pyramidal B frames Checked
Motion Estimated Method - Uneven Multi Hexagon
Subpixel Motion estimation - 9
Motion Estimation Range - 24
Trellis - 2
No fast P skip checked
No DCT decimate checked

Looked like shit took forever and didnt save much space.
 

Cogman

Lifer
Sep 19, 2000
10,284
138
106
Did use i7

Following were changes from High Profile Preset built in to Zebo's custom preset

-Video tab Constant Quality 76.96%

-Subtitles tab - Burn in forced

-Advanced
Direct prediction - automatic
Pyramidal B frames Checked
Motion Estimated Method - Uneven Multi Hexagon
Subpixel Motion estimation - 9
Motion Estimation Range - 24
Trellis - 2
No fast P skip checked
No DCT decimate checked

Looked like shit took forever and didnt save much space.

What the crap is 76%, that makes no sense when dealing with x264. Try doing small clips and testing the quality, lower till you see a difference.

Just downloaded handbrake to see what you where talking about. the 76% is a very high CRF (11), it should look pretty much the same as the video you put in. What does the video look like? Are you using High profile? How many reference frames do you have? Are you doing mixed references?

Can you post a screen shot of the crap version vs the input?
 
Last edited:

JAG87

Diamond Member
Jan 3, 2006
3,921
3
76
Make sure you are using 16 ref frames, enable mixed references, crop the black bars, use a low number of b frames (3 is fine), increase motion estimation range to 64, enable 8x8dct. You haven't mentioned if you are using CABAC entropy, you should. You should also use -3 deblock and -3 threshold, but this can change depending on the material. The rest of the settings you picked are fine, a CRF or 11 is retarded, you can achieve transparency on 480p material at CRF 22, sometimes even a bit lower. Handbrake will not let you select a profile or level, it will use the appropriate one for your video. In the OP's case, it will use either Hi@L3, or Hi@L3.1 if the bitrate peaks too much.

If you use these settings, it will take you 2-3 hours per movie to encode, the output will be 1/8th of the original, and the quality will be indistinguishable. You can then mux your AC3/DTS track, some SRT subs, and make a nice mkv. Whole movie should be no more than 1GB, a bit larger with DTS.

EDIT
I thought I'd add that you can remux the mpeg2 and one english track into an mkv, and you would probably shave 1-2 GB per dvd with no quality loss whatsoever.
 
Last edited:

Allio

Golden Member
Jul 9, 2002
1,904
28
91
I thought I'd add that you can remux the mpeg2 and one english track into an mkv, and you would probably shave 1-2 GB per dvd with no quality loss whatsoever.

MakeMKV has a one-click interface for doing this from a DVD, it's great.