View Full Version : "YUV 4:2:0 Planar" or "Y'CbCr 8-bit 4:2:2 (yuv2)" in QTGMC ?
the_tourist
27th July 2015, 22:00
Hi,
I hope to post this request for help in the right place, but I'm not sure.
I am a very beginner in the use of Avisynth and I'm afraid that all this is beyond me at the moment ...
My goal is de-interlace QTGMC by the rendering of an edit I made from sequences in DV.
Following the indications of Rob Martens site http://www.gyroshot.com/upscale1.htm (SD to HD with Avisynth) I managed to install a functional QTGMC under WindowsXP.
I edit with cinelerra-cv 2.2 (linux), this software does not allow to realize rendered consistent with YV12 or YUY2 color space. His two formats that are closer to it, are "YUV 4: 2: 0 Planar" or "Y'CbCr 8-bit 4: 2: 2 (yuv2)" but the two did not open in VirtualDub.
The only solution I found is to do rendering in "YUV 4: 2: 0 Planar" And Then convert it by Avidemux in "YV12 (raw)" for VirtualDub to finally be willing to accept it. My problem, solved Would Be, If It Was That Avidemux only refuse to open the render too large file (38GB) from my 40-minute documentary in DV ...
For several days I have read a lot of text on Doom9, looking for a recipe That will permit to assurer que la render files of cinelerra-cv are accepted by Avisynth and VirtualDub. It Seems to be feasible with QTSource, and Perhaps with FFmpegSource. For the moment I do not know how to do it and I did not find instructions to do so.
I need help, I am very far from understanding the system of scripts and plugins, but I'm sure if I can use QTGMC to de-interlace my edit, the results will correspond to what I seeks.
ChiDragon
27th July 2015, 22:43
If your source is NTSC DV (4:1:1) I think you would be better off working with 4:2:2 until the very end when you're at your final HD resolution; then drop to 4:2:0. You should be able to preserve more of your color information that way rather than going 4:1:1 -> 4:2:0 = "4:1:0" prior to upscaling, particularly given the limitations of interlaced 4:2:0.
Perhaps you can upload a small sample of a 4:2:2 file created by cinelerra-cv. 10 frames should be more than enough.
the_tourist
28th July 2015, 03:29
Hi ChiDragon,
Thank you to answer.
Yes my source sequences are NTSC DV 4:1:1 and I understand why you recommended me to favor the rendering mode of Cinelerra-CV in 4:2:2 ("Y'CbCr 8-bit 4:2:2 (yuv2)".
I had not mentioned but cinelerra-cv also offers another variant of a rendering in 4:2:2, it is the "Y'CbCr 8-bit 4:2:2 (2vuy)"
So I am sending you a compressed file containing two very short rendering of cinelerra-cv in 4:2:2, a first in Y'CbCr 8-bit 4:2:2 (yuv2) and the other in Y'CbCr 8- bit 4:2:2 (2vuy). They are available at the following link:
http://dl.free.fr/ta2wWbKkb
What interests me is how to do, to force QTGMC to accept and de-interlaces, at least one of these formats. I need detailed help to get there, because I am a very beginner, with Avisynth.
Thank you for your support.
ChiDragon
28th July 2015, 17:12
What have you used that plays the 2vuy file correctly?
MPEG Streamclip on Windows opens the yuv2, but the 2vuy is displayed garbled (at least with my Streamclip & QuickTime version).
QTSource (http://forum.doom9.org/showthread.php?t=104293) performs the same way. So you should be able to use that as your source filter in Avisynth to import the yuv2 file so that you can apply QTGMC and any other filters to it.
You don't need to specify any settings for it work with the yuv2, just QTInput("filename.mov"). Note that it will be losslessly converted to YUY2.
the_tourist
29th July 2015, 01:46
I do not use anything to open 2vuy files, HandBrake does not decode them, so I do not use them. I have mentioned this second rendering option with cinelerra-cv, only in case you could find it useful.
The format that I normally use for rendering is "Y'CbCr 8-bit 4:2:2 (yuv2)" because HandBrake reads this file type, and then I can produce my compressed versions.
Handbrake also allows de-interlacing the video, but the quality that results is not very good; it produced too many artifacts. That is why I want to use de-interlacing with QTGMC of my render files from cinelerra-cv, and then produce the compressed versions.
I do not know MPEG Streamclip, but could he communicate with Avisynth to use QTGMC ?
So I followed your instructions... I intalled QTInput, I replaced the line AVISource("filename.mov") by QTInput("filename.mov") in the .avs file,
also ConvertToYV12 (interlace=true) by ConvertToYUV2 (interlace=true).
And it works!
The video was de-interlaced properly with QTGMC.
Fantastic, thank you very much for your help.
However...
The video is now silent... there is no sound...
What should I do to get the sound ?
If QTSource can not process the sound, would FFmpegSource be an alternative ?
creaothceann
29th July 2015, 15:33
Try adding AudioDub(last, DirectShowSource("filename.mov", video=false))
ChiDragon
29th July 2015, 21:54
also ConvertToYV12 (interlace=true) by ConvertToYUV2 (interlace=true).
Adding ConvertToYUY2 isn't going to do anything when the source is already YUY2.
I don't believe you've said what you're targeting as your destination format. If your final output is going to be an interlaced resolution like 1080i, take care to use ConvertToYV12(interlaced=true) at the end of the script so that the proper conversion is done and you don't have to rely on the encoder.
the_tourist
30th July 2015, 04:29
@creaothceann
Thank you!
It worked and I found the sound of my sequence.
Questions:
1- Should I put the line AudioDub ... before or after that of QTInput? Is it important?
2- Is it possible to combine these two lines of instructions, so it is necessary to include the "filename.mov" (including its path) only once for the two types of instructions?
3- Do AudioDub transforms the sound or is it a simple copy without any degradation?
@ChiDragon
At this time, the output QTGCM (Avisynth VirtualDub) is Huffyuv and progressive (although still MediaInfo says Interlaced ...). With this "Master", I will initially manufacture (with HandBrake), the compressed version H264 which will go on Youtube or Vimeo.
Secondly, I will make a master DVD with various menus, which will be reproduced for distribution to a specialized network.
Even for the DVD, it was important that video, be de-interlaced (as well as possible) because the DV material was filmed 16/9 and when made to play on an old CRT TV 4/3 (which may yet happen in this network which is not fully modernized) These CRT very mismanage 480 lines of the image in 16/9 ... the result is a very big and painful comb effect.
My current need for QTGMC is solved and I Thank You.
The next editing DV footage, I would rather de-interlacing with QTGMC ... BEFORE editing ...
I would like to find out how to batch process automatically (QTGMC) a long list and DV sequences while maintaining the title files (except the extension) when converted.
I also want to find how to make DNxHD encoding rather than Huffyuv (cinelerra-cv does not accept Huffyuv files input).
Another challenge ... I would also like to learn how to use QTGMC directly and natively under Linux. I think I read that it was now possible with VapourSynth but I expect many difficulties before I get there ...
That's for another time ...
A brand new fan of Avisynth ...
creaothceann
30th July 2015, 18:38
Should I put the line AudioDub ... before or after that of QTInput? Is it important?
After QTInput.
Is it possible to combine these two lines of instructions, so it is necessary to include the "filename.mov" (including its path) only once for the two types of instructions?
These are all equivalent:
f = "filename.mov"
v = QTInput(f)
a = DirectShowSource(f, video=false)
AudioDub(v, a)
f = "filename.mov"
AudioDub(QTInput(f), DirectShowSource(f, video=false))
f = "filename.mov"
QTInput(f).AudioDub(DirectShowSource(f, video=false))
Do AudioDub transforms the sound or is it a simple copy without any degradation?
"AudioDub(clip1, clip2)" takes the video from clip1 and the audio from clip2, combines them and returns the result. It doesn't modify the data in any way.
the_tourist
31st July 2015, 05:34
@creaothceann
Thank you for your support,
My test computer is inaccessible today, in a day or two I will try your various proposals. For the non-coder that I am, that language of scripts is very strange and surprising in its logic. But I will make the effort to understand it, because it seems to allow some very interesting things with video.
the_tourist
31st July 2015, 18:37
@creaothceann
Well, I was finally able to test your code options, obviously everything worked.
I preferred the third option, which I find simpler and clearer.
With all this I consider the issue of use of sources in yuv2 format solved.
When I have some more questions (which will certainly happen) I will create new treads.
Thank you to all
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.