Hello, I have been using Vidcoder to encode my DVD's and Blu-rays, but I am having problems encoding this file, I have tried using Megui, whilst it gets rid of some of the noise or grain, it always resizes it. How is it best to encode this source?
I want to crop the black bars without resizing.
I am using Windows 10 64-Bit.
+ Reply to Thread
Results 1 to 11 of 11
Are you trying to encode to mp4/mkv or are you trying to maintain the mpeg-2/interlacing so you can make a DVD ?
Vidcoder/MeGui implies the former but wanted to check.
What does it resize it to? If you turn off the small amount of cropping in Vidcoder, it keeps the 720x576 but stretches it to 768x576 upon playback
Or, auto cropped 692x552, 738x552 @ playback
Last edited by davexnet; 6th Aug 2020 at 12:02.
MediaInfo specs needed.
To diagnose the problem with MeGUI, perhaps uploading the corresponding log file (found in the “logs” subfolder) would be helpful.
It's a lot more flexible than the likes of Vidcoder (which if I remember correctly is based on Handbrake and does not accept Avisynth script as input – and Avisynth gives access to many solutions for advanced processing purposes, including denoising), but there are a lot of options and settings and windows and menus so it's got a steeper learning curve.
Mod4 is set here:
Normally if you uncheck “Resize”, MeGUI shouldn't resize at all.
If you check “Clever anamorphic encoding”, then “Encode non-mod16", it will also disable resizing. Then you have to verify if the resulting resolution (after cropping) is compatible with the encoder's requirements.
If I remember correctly, HEVC / x265 should be fine with a “mod2” resolution ; if not, cropping 2 pixels less on the right – crop(14, 12, -14, -12) – lets a tiny remnant of black border on the right side but results in a mod4 width so no resizing is required.
Regardless of the GUI options, you can always modify the Avisynth script (“Script” tab), and for instance remove the resizing line if it's not what you want. See MeGUI as a mere convenience to make various CLI tools and scripts interact in a sensible way for intermediate users who want better control and more options than what more straightforward GUIs like Handbrake / Vidcoder offer, but not yet confident enough to fully understand the intricacies of what's going on under-the-hood to design their scripts from scratch. (And the problem is that most advanced users on this forum are beyond that stage and don't use MeGUI so won't be able to help much when it comes to MeGUI's specific settings ! é_è)
As for deinterlacing, QTGMC should be significantly better than Yadif. Even if using Yadif (QTGMC is much slower but if you're encoding with x265 the computer must have enough oomph, and/or you must have enough patience, so this should not be an issue), preferably use “Yadif (with bob)”, which will double the framerate to 50 FPS (each interlaced field gets interpolated into a full frame), but preserve all the motion information, resulting in a much smoother playback. That's the default behaviour with QTGMC. The resulting size of the re-encoded files should not be much higher despite the doubled framerate, as encoders like x265 efficiently detect redundancies between adjacent frames.
But it still loaded mpeg2source afterward, weird...
DGDecode_mpeg2source("C:\Users\***\Desktop\ruwkljv 5.3e5\VTS_01_1_001.d2v", cpu=4, info=3)
I know nothing about using MeGUi's OneClick encoder, but when using the Script Creator, if you enable anamorphic encoding and select "encode non-mod16", MeGUI won't adjust the cropping or resize, so you have to make sure you crop to mod4 (or whatever) dimensions yourself. The script Creator has a preview so adjusting the cropping manually is easy.
If you select "resize to the selected mod", MeGUI will allow you to resize and automatically resize to the selected mod if need be. This won't distort the picture as the pixel/sample aspect ratio used for encoding will be adjusted accordingly. There's also a couple of anamorphic options that tell MeGUI to adjust the cropping to achieve the selected mod rather than resize.
There's some pics attached showing how I configured the Script Creator to encode your sample. I created a custom Input DAR of 15:11, as that'll give you an mpeg4 compliant pixel aspect ratio (if you prevent MeGUI from fudging the pixel aspect ratio and don't resize). Not that it matters too much, but the next best choice for your sample would be to choose the ITU 4:3 PAL Input DAR. If you're using the OneClick encoder, there's a "Use ITU Aspect Ratio" checkbox in MeGUI's general options. It's probably enabled by default.
If you compare the attached sample to the one davexnet uploaded you'll see the picture is stretched a little wider, as Vidcoder assumes an exact Input DAR of 4:3. I gather it's a BBC DVD? If so an mpeg4 or ITU Input aspect ratio is probably correct (either one is fine, as they're virtually the same).
Image1 shows how I set the Input DAR, anamorphic encoding and cropping.
Image2 is the filtering. Yadif for de-interlacing will deinterlace to 25fps. Yadif (with Bob) will de-interlace to 50fps and motion will probably look smoother.
Image3 is how the script looks. MeGUI uses the display aspect ratio at the top (when anamorphic encoding is enabled), to calculate the correct pixel/sample aspect ratio for encoding.
Image4 is the Avisynth configuration. You get to it by clicking the "Config" button next to the Avisynth profiles on the script creator's I/O tab. The main one you might want to adjust is the Acceptable Anamorphic Aspect Error. Setting it to zero prevents MeGUI from fudging the aspect ratio. I think the default is 1%. It's up to you, but higher values make it easier to crop to an exact 4:3 or 16:9 display aspect ratio. If it's set to zero and you use a 15:11 Input DAR, the pixel/sample aspect ratio will be 12:11 for your PAL source, if you use anamorphic encoding and resizing is disabled.
Job command line: "C:\Program Files\MeGUI\tools\x264\x264.exe" --level 4.1 --preset slow --tune film --crf 18.0 --b-adapt 2 --me umh --stitchable --colormatrix bt470bg --sar 12:11 --frames 3624 --output "D:\VTS_01_1_001.mkv" "D:\VTS_01_1_001.avs"
Image5 is MPC-HC displaying the encoded video's display aspect ratio (373:274). It's been rounded to three digits but it's basically the same as the aspect ratio at the top of the script (2052:1507).
There's a sample encode attached. Yadif (with Bob) for 50fps.
I have played around with Megui and the best settings used in Megui I found can be replicated in Vidcoder,
I am using 19 CRF, my deinterlacing settings are Yadif with bob and NLMeans denoiser medium and a deblocking setting of 8, the width is 720 with the black bars cropped off and non-anamorphic.
THank you all for your help.