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. |
15th October 2003, 16:53 | #1 | Link |
Registered User
Join Date: Jan 2003
Posts: 62
|
ColorBars() luminance levels
I am using a ColorBars(720, 480) to test some luminance level settings.
What is the luma level of the bottom right corner black quadrate and the most black part in the picture, a tiny black vertical strip? It seems to me that they are 29 and 22 respectively. Is this correct? I mean when the ColorBars are in RGB or converted to YUY2 but not expanded to 0-255 in the photo editor software or some other video editing tolls which use RGB for processing. |
16th October 2003, 15:04 | #4 | Link |
Simply me
Join Date: Aug 2002
Location: Lancashire, England
Posts: 610
|
What was it (for future reference) ?
regards Simon
__________________
http://www.geocities.com/siwalters_uk/fnews.html |
16th October 2003, 19:08 | #5 | Link |
Registered User
Join Date: Jan 2003
Posts: 62
|
Until it is in RGB24, as originally generated by Avisynth, the bottom right corner black quadrate’s luma = 16 and the most black part in the picture is a tiny black vertical strip, he’s luma = 7.
When it is converted in Avisynth to YUY2 or YV12 a luminance range is compressed by ratio "0-255 to 16-235". They will become approx. 30 and 22 respectively. It is clearly seen by running a as script: ColorBars(720, 480) ConvertToYUY2() ColorYUV(analyze=true) ConvertToYV12() Histogram() If an avs file above (with the last three lines deleted) will be opened in RGB-required software, a luma range will be expanded back to 0-255, those two black areas will have levels 16 and 7 respectively. Buy using ColorBars() I’ve found that in CCE encoder "Luminance Level 16-235" CHECKED is the correct setting for DV avi material if it comes in to CCE as RGB color space-based. |
17th October 2003, 00:05 | #6 | Link |
Simply me
Join Date: Aug 2002
Location: Lancashire, England
Posts: 610
|
I'm a bit confused (nothing unusual there then )
Colorbars generates RGB. Each colours range is normally 0 - 255 Avisynth's normal YUV range is 16-235 (for Y, 16-240 for U and V) so any RGB source will be converted to a Y range 16-235 (unless the conversion is broken) So how can any Y value of any part of the colorbars be less than 16 when thinking/using Avisynth ? regards Simon
__________________
http://www.geocities.com/siwalters_uk/fnews.html |
17th October 2003, 13:10 | #7 | Link |
C64
Join Date: Apr 2002
Location: Austria
Posts: 830
|
don't fear, it's not <16
When you are in RGB and R=G=B=0 you cannot say this is luma=0 (because you still are in RGB) And Histogram and ColorYUV are YUV-only-functions. The only point is that CCE/TMPG can be told which Y range to use when CREATING YUV THEMSELVES: 0-255 (will make "superwhite" and "superblack" areas) 16-235 (as AviSynth and CCIR601) ProCoder (at least 1.0xx) will always use 0-255, so you have to do a pseudo-conversion 0-255 > 16-235 in RGB before. |
17th October 2003, 19:44 | #8 | Link |
Registered User
Join Date: Jan 2003
Posts: 62
|
@WarpEnterprises, thanks for correcting. When I was saying about RGB color-space luma = 16, luma = 7 I meant RGB(16,16,16) and RGB(7,7,7).
I totally agree with all your notes. The only thing about encoder, if a clip comes into CCE as YUY2 you cannot tell CCE which Y range to use. CCE will not change luminance range. It will take everything in 0-255 range and will create mpg with the luma 0-255. You need take care about not having nothing below 16 and above 235 before it comes into the encoder, if it needs to comply with CCIR 601. The bad thing is that DV avi’s (at least from MiniDV tape) usually have some over-ranges. If it will be directly imported into RGB color-space- required editing software, a luma will be expanded to 0-255 range. All those over-ranges which have some valid info will be cut-off. It needs to be corrected before it gets into the encoder. Last edited by Bordo32; 17th October 2003 at 20:01. |
17th October 2003, 20:27 | #9 | Link | |
Simply me
Join Date: Aug 2002
Location: Lancashire, England
Posts: 610
|
Quote:
AFAIK DV is REC-601 compliant so the Y values range from 16-235. regards Simon
__________________
http://www.geocities.com/siwalters_uk/fnews.html |
|
17th October 2003, 22:27 | #11 | Link |
Simply me
Join Date: Aug 2002
Location: Lancashire, England
Posts: 610
|
Just re-read Adam Wilts DV-FAQ and I see what's meant by over-ranges now
Ta regards Simon
__________________
http://www.geocities.com/siwalters_uk/fnews.html |
17th October 2003, 22:38 | #12 | Link |
Registered User
Join Date: Jan 2003
Posts: 62
|
MiniDV camcorders do not handle 16-235 luma range accurately enough.
If DV avi file will go into RGB color-space editing software, Vegas Video for example, YUY2 will be converted to RGB and the luma will be expanded to RGB 0-255 range. YUY2 to RGB conversion will be performed by the ratio "16-235 to 0-255". Some valuable info below 16 and above 235 will be lost. A luminance levels need to be corrected, in Avisynth for example, before an avi gets into the RGB color-space. |
|
|