Okay so,
I own a LOT of physical DVDs and I also run a small Plex server that my family has access too throughout the household. I decided that I wanted to start digitising some of my physical media, especially some of my more rare and obscure titles that I've picked up over the years. --
My overall goal is to rip these DVDs to their highest possible quality and then compress with H265 to a more Plex friendly format and size. I've chosen H265 because I believe its the future in video codec and I love the small size to quality ratio that it produces..
I'm quite new to video encoding, but I've done quite a bit of research over the past few days. I guess the point of this post is to document the process I went through and receive some kind of validation that I done it "correctly".
The DVD I am using as an example in this post, is a cartoon TV series. The DVD contains about 9 episodes and each episode is about 20 minutes long. The goal is to rip the episodes into individual files, compress them to H265 and scan them into my Plex library.
MakeMKV
The first thing I done was insert the DVD into my drive and load up MakeMKV. The software scanned the contents of the disc and I quickly found out that the episodes were annoyingly not individually broken up into their own titles or chapter. But rather just stitched as one giant 3 hour title. - So I dumped (or remuxed???) the disc to my hard drive which resulted in me having this 7gb, 3 hour, mkv file.
VirtualDub2
Because I wanted the episodes individually broken up into their own seperate files, I wanted to try and find a way to manually break them up, without having to edit, compress and compress again. Doing this would have degraded the quality. So I opted to go with Virtualdub2, because at least then I could split the episodes up and save them with a lossless codec.
So I opened the giant mkv file in Virtualdub2 and noticed that the video was interlaced. I applied a YADIF de-interlace filter and separated the fields into their own frames. This straight away turned my mkv file from 25fps to 50fps. I then proceeded to manually break the episodes up into their own individual files and save each one as an avi using utvideo lossless codec.
HandBrake
So I now have 9 episodes broken up into individual files in the avi format. Keep in mind these episodes are GIANT in file size because of the lossless codec. The last part of this "project" is to compress them down into H265. So I load all 9 episodes up into Handbrake. These are the settings I opt for:
- MKV
- Dimensions: 720x576
- Video Codec: H265
- 50fps @ Constant Rate
- Encoder Preset: Medium
- Tune: Animation
- Constant Quality: 20
- Audio: 128k Stereo
Everything else I either left default or auto.
Each episode encoded and averaged a file size of about 100-150mb. -- I scanned them into my Plex library and streamed them on my TV and they looked absolutely great! (for DVD quality).
Question 1: So was this the correct way to rip my DVD, split the episodes manually and compress?
Question 2: When compressing in Handbrake, should I have restored the episodes back to 25fps (how they originally were before de-interlacing)? Or was it fine to leave them at 50fps?
Question 3: When using a constant quality to encode video, why do file sizes vary so much? In my case, each episode was about 20 minutes long and they were all encoded using a constant quality of "20", so why is one episode 190mb and another episode 100mb? Why is there such a jump in file size?
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 11 of 11
Thread
-
-
Since ripping - by definition - means to put them on the hard drive minus any encryption and region coding, then they'll automatically be in the 'highest possible quality'.
But rather just stitched as one giant 3 hour title.
I applied a YADIF de-interlace filter and separated the fields into their own frames. This straight away turned my mkv file from 25fps to 50fps. I then proceeded to manually break the episodes up into their own individual files and save each one as an avi using utvideo lossless codec.
You had best provide a sample direct from the DVD. With it already decrypted to the hard drive you can cut a 10 second portion from a VOB - one with steady movement - using DGIndex. Use the [ and ] buttons to mark a section and then File->Save Project file and demux video. Upload the resulting M2V here. -
You probably ruined them by applying Yadif to deinterlace and bob (double the framerate). Once degraded like that, the rest of your workflow is useless.
Here you go: https://www.dropbox.com/s/au9qjgey0ddveyp/Sample.demuxed.m2v?dl=0Last edited by ThaKarra; 30th Oct 2020 at 16:20.
-
I'll try to clarify a few things...
manono is correct in that "RIPPING" is basically a straight copy (minus encryption stuff) to harddrive. In this state, it is either ISO (the whole disc as an imagefile), or *.VOB (and possibly also *.IFO and *.BUP) files within a VIDEO_TS folder. Those VOB files include the MPEG2 video and associated audio, etc. Straight stream copy = no further quality loss = same quality as was on the disc.
ANYTHING ELSE is "RIPPING + Converting"...
manono is likely also correct in that:
1. Film-based videos should normally NOT ever be "deinterlaced", but rather InverseTelecine'd (aka IVTC). This properly restores the progressive image without removing any fields and without introducting any blended/interpolated fields. This is less important to need to do in PAL lands (like Australia) than it is NTSC lands, but is still important.
2. De-interlacing can be done many ways, but unless you are careful, you can very likely be introducing interpolated fields. When you combine that with further resolution or motion processing (scaling, framerate conversion) you are just compounding the error.
If you had a film-based source, and set up Yadif such that it was only recombining odd & even fields, this would be the equivalent of PAL-based IVTC, and that would be OK. But any OTHER setup is very likely to become problematic down the line.
Also, while you are partially correct about h265 being more efficient (it depends on the source, the settings, and the resolution) and that it'll be around in the future (though many other codecs will too), it MIGHT NOT be the best option for you if you are sharing the files via DLNA/NAS to your family. Depends greatly on what the lowest common denominator base of hardware you all have. Unless it is all quite modern (~2016->) there will likely be devices that will either have a hard time playing such clips, or won't play them at all.
That is why h264 is still the most common codec: any modern equipment (~2004->) should be able to play it easily. And I would guess that the difference between the 2 codecs isn't is wide as you think (certainly not 2:1). h265 shines with UHD material, but at lower resolutions the 2 tend to converge in quality/filesize.
And since as you say you're starting from DVDs (aka standard def, not HD nor UHD), this would more likely favor h264 for universality.
Scott -
Hey Scott thanks for the reply.
Before I reply to your post, I just want to start by posting 2 things.
- This is the sample M2V file that manono requested in the post above. Its directly from the source VOB - https://www.dropbox.com/s/au9qjgey0ddveyp/Sample.demuxed.m2v?dl=0
- This is a sample MKV of the exact same clip, but compressed with H265 using my method and all the steps that I mentioned in the original post above - https://www.dropbox.com/s/s2mdtsx4kfzffqt/Sample.zip?dl=0
I just wanted to post them, that way people can analyze and directly see the result of what I'm talking about in the original post above.
I should also mention I live in Australia, so our standard here is PAL. The DVD in my example is PAL however I do have NTSC DVDs in my collection that I will also want to end up digitising.
This is very interesting. When I imported the .mkv that MakeMKV spat out into VirtualDub2, this is the exact de-interlace setting I used. - I used no deinterlace settings within Handbrake at all when compressing to H265.
[Attachment 55683 - Click to enlarge]
I'm going to assume based on what you said, this was the wrong move.
Also, while you are partially correct about h265 being more efficient (it depends on the source, the settings, and the resolution) and that it'll be around in the future (though many other codecs will too), it MIGHT NOT be the best option for you if you are sharing the files via DLNA/NAS to your family. Depends greatly on what the lowest common denominator base of hardware you all have. Unless it is all quite modern (~2016->) there will likely be devices that will either have a hard time playing such clips, or won't play them at all.
That is why h264 is still the most common codec: any modern equipment (~2004->) should be able to play it easily. And I would guess that the difference between the 2 codecs isn't is wide as you think (certainly not 2:1). h265 shines with UHD material, but at lower resolutions the 2 tend to converge in quality/filesize.
And since as you say you're starting from DVDs (aka standard def, not HD nor UHD), this would more likely favor h264 for universality.Last edited by ThaKarra; 30th Oct 2020 at 18:25.
-
That's an unusual sample. It's almost all progressive with only a few interlaced frames. Is the whole thing like that (mostly progressive)? What I eventually decided to do was to deinterlace only those few frames (7, I believe) that were interlaced, leaving the rest alone. This is nothing HandBrake can do. Here's the AviSynth script:
MPEG2Source("Test.d2v")
Orig = QTGMC(FPSDivisor=2)
TDeint(Full=False,Clip2=Orig)
If you're going to work with animations, you should learn some AviSynth and lose HandBrake. Here's your sample reencoded as an MP4:Last edited by manono; 30th Oct 2020 at 20:31.
-
That sample is mostly progressive frames. But there were a few interlaced frames. I would use TFM() to fix those, not a deinterlace.
Code:Mpeg2Source("Sample.demuxed.d2v", CPU2="xxxxxx", Info=3) # deblock and dering TFM() # cleans up frames 106, 108, 110... # color correction, denoise, etc.
-
Oh thanks so much for taking the time to help me with this. I really am trying to do research and learn.
I'm not sure if the whole DVD is like that. It's a 2 Disc set. I just grabbed a random clip for you. There is definitely a lot more interlacing throughout the actual episodes though.
I watched a couple of AviSynth tutorials for deinterlacing and now I'm just messing around with plugins and scripts trying to learn the ropes.
I decided to give it another attempt with some different footage from the DVD, this time the episode intro. You can clearly see that the whole thing is interlaced this time.
- Original source - https://www.dropbox.com/s/h6khkbz0gk1hhsc/Sample2.demuxed.m2v?dl=0
- My Attempt - https://www.dropbox.com/s/9qwxwgb9yo3m78j/Sample2.zip?dl=0
Fingers crossed this time I think I've done it correctly.
This is the script I used. I'm going to be honest, I don't really know what it does (yet, I will learn), I basically just followed a YouTube tutorial step to step (https://www.youtube.com/watch?v=1s6XNCVUBdE)
Code:MPEG2Source("Sample2.d2v") tfm() BilinearResize(720,576) vinverse()
I used the TFM plugin in this attempt! -
Yes, much more interlacing. Maybe TFM is better after all, with a better deinterlacer used instead of the default one:
Mpeg2Source("Test.d2v")
tdeintted = QTGMC(FPSDivisor=2)
TFM(clip2=tdeintted)
Crop(2,4,-2,-2)
Spline36Resize(792,576)
That tells TFM to use the better QTGMC for its post processing instead of the default deinterlacer. As for your video, it's already 720x576 so I'm not sure why you added a resize to the script. However, something should be done as it's not meant to be shown at 720x576. I showed one possibility in the script above. Or fix the AR when setting up the encode. And the use of Vinverse is usually a safe bet as it isn't known for deinterlacing when it's not needed.
As you know, when using TFM, especially with animations, it sometimes deinterlaces a progressive frame. The TFM settings can probably be tweaked.
Mpeg2Source("Test.d2v")
TFM(Display=True) -
Yeah I have a bad habit of adding resize to things, even when I don't need too... I guess my reasoning is because I want to confirm the size regardless. But you're right its totally unnecessary.
However, something should be done as it's not meant to be shown at 720x576. -
Yes, but the DAR is 4:3. All PAL DVDs are 720x576, but the DAR might be either 4:3 or 16:9 and they get resized differently at playback time. To get the correct resolution, multiple 576 by either 4/3 or 16/9 to get the resized width. When reencoding to a different format you can either resize to the proper aspect ratio (as I did in that script) or set a flag in the video to have the player do the resizing at playback time (similar to the way a DVD player resizes a DVD during playback). I also cropped away the black so the resize changed somewhat. And what I wrote is a bit of a generalization.
Similar Threads
-
Process for Ripping DVDs for Editing in Premiere Pro?
By GothPanda in forum DVD RippingReplies: 2Last Post: 17th Dec 2017, 21:47 -
To GPU process, or not to GPU process ? 450fps HD -> SD
By hydra3333 in forum Video ConversionReplies: 9Last Post: 28th Nov 2017, 07:01 -
Process aborts during DVD Authoring operations
By Ladywolf in forum Newbie / General discussionsReplies: 1Last Post: 26th Apr 2017, 14:12 -
I need help finding the correct DVD Recorder.
By dafoe in forum DVD & Blu-ray RecordersReplies: 11Last Post: 15th Sep 2016, 10:43 -
What software and process do I need to burn surround sound mix to DVD?
By richiwebb in forum MacReplies: 2Last Post: 28th Feb 2016, 20:19