Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. Domains: forum.doom9.org / forum.doom9.net / forum.doom9.se |
|
|
#1 | Link |
|
Advanced Blogging
Join Date: May 2009
Posts: 480
|
Explanation of YUV X:X:X notation
I know that the different YUV chroma sub-sampling formats are given the notation 4:x:x, with YUY2 being 4:2:2 and YV12 being 4:2:0. My question is, what does this numerical notation indicate? I have read the YUV article on Wikipedia, but it does not explain what this notation means.
|
|
|
|
|
|
#2 | Link |
|
Un-Registered User
Join Date: Mar 2008
Location: Audio Stream - 0x80
Posts: 341
|
I'm a noob, so this might be wrong, But:
The numbers represent the vertical resolutions given to the Luminance and Chrominance of a color space. The first number usually represents the Luminance (Y), the second represents the Blue minus the Luminance (Cb), while the third represents the Red minus the Luminance (Cr). Green minus the Luminance is not stored becuase it can be calculated by subtracting the Cb & Cr from Y. So for something like 4:2:2, each pixel would have a Luminance sample, but only 2 out of every four (vertical & horizontal; so truly only 1/4 of the pixels are given a color sample) would have a Cb and Cr sample. The exception is 4:2:0 which should really be 4:0:0 It can be illustrated like such for a 4:2:0 colorspace: 0=Y 1=Y+Cb+Cr Code:
1 0 0 0 Code:
1 1 1 1 |
|
|
|
|
|
#3 | Link |
|
Registered User
Join Date: Jan 2009
Location: UK
Posts: 403
|
The first digit represents the number of horizontal pixels we're considering. Although this can have any value it always seems to be 4. It's also implicit that we're looking at two lines at a time. So with the first digit as 4 it means that we have a 4x2 (horizontal by vertical) block of pixels.
The second digit indicates how many chroma samples are taken from the top line of each block of pixels, and the third digit indicates how many are taken from the bottom line. e.g. 4:2:2 results in each chroma sample representing a 2x1 block of pixels - 2 samples per line of four pixels. Code:
x represents a chroma sample, o doesn't xo|xo xo|xo Code:
xo|xo oo|oo Code:
xooo xooo Last edited by TinTime; 2nd August 2009 at 11:22. Reason: Added another example |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|