View Full Version : Yv12, Rgb, Yuy2, Uyvy ????
I don't know where to put this question. But here goes: Can anyone explain for me what this is all about?
I use Gordian Knot 0.28. If I write an avs with .converttoyv12() I will get a nice preview window when I open the avs in GKnot. If I use .converttoyuy2() or write no such at all, I will get an all gray preview.
However, If I try to encode with the setting .converttoyv12(), I will se nothing at all or maybe some green screen. If I use .converttoyuy2(), the encoding will be fine.
So what is in all this, yv12, yuy2 and so on?
ultimatebilly
5th May 2003, 13:58
yv12 and yuy2 are different colorspaces, that means different ways the color is stored in the frame.
In RGB there is the full color-information for each pixel, yv12 and yuy2 work with color-components, they store only b-y and r-y, because this is sufficient to calculate g-y... (y is the brightness, b=blue, r=red... RGB=Red, Green, Blue...)
yuy2 and yv12 only store a quarter of the color information of rgb, because the human eye is less aware of changes in color than of changes in brightness.
I can't tell you the exact difference between yv12 and yuy2, but I can tell you that you can only use yv12 with a appropriate decompressor installed (Xvid or divx5), and you have to use virtualdubmod or avs2avi to encode in yv12, virtualdubmod has to be set to fast recompress (otherwise virtualdubmod will convert to rgb and back to either yuy2 or yv12, don't know which...)
The main advantage of using yv12 is the speed-gain, because yv12 is the format used in DVD-Video...
You should only use converttoyuy2() when you compress to mpeg2 or mpeg1 with cce, with tmpeg you have to use converttorgb().
In Virtualdubmod, use mpeg2dec3.dll, and use fast recompress, and don't add converttoanything() into the script...
If you want to use filters in virtualdubmod, then you should use converttorgb()...
About the right forum:
Why don't use the newbie-forum for questions like these?
PS.: I have some bookmarks regarding these topics at home, if you are interested surfing a bit deeper into the topic I could post them later...
hakko504
5th May 2003, 14:15
Read the AviSynth FAQ Q3.1 (http://www.avisynth.org/index.php?page=Section+3%3A+Filters+and+colorspaces)! It contains answers to most of the questions as well as a number of interesting links.
i've also posted some newbie-friendly intro to colorspaces on this thread:
http://forum.doom9.org/showthread.php?s=&threadid=52153
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.