YUV->RGB (16-235 to 0-255) BANDING FIX.

For questions and discussion that is NOT (I repeat NOT) specific to a certain Operating System.
Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 04 Sep 2013 12:56

Hi.

Been using VLC for many years,
I just noticed that there is banding when playing a smooth grey ramp (gradient) video from AVSHD709.

Grey Ramp Video (very trusted source):
http://w6rz.net/avshd709/MP4-2c.7z
Misc Patterns -> A - Additional -> 1-Grayscale Ramp.mp4

This happens when I set the Dynamic Rang in NVIDIA to Full (0-255), as it should because of "stretching" from YUV to RGB.
It fixes the Black & White limits, but creates ugly banding.
When I leave it at 16-235, the B&W limits are wrong, but the banding is non existent.
Everything works as it should (expected).

I have found a way (trick) to fix the banding in the RGB (0-255) without sacrificing anything.

Make these adjustments and play the "Grayscale Ramp.mp4" file to test:
Tools -> Preferences -> Show Settings (All) -> Video-Filters-Grain -> Variance: 2.00, Minimal Period: 1, Maximal Period: 1.
Save.

Tools -> Effects & Filters -> Video Effects -> Essential:
Turn On: Banding Removal, Radius at 0 (minimum).
Turn On: Film Grain, Variance at 2 (second line).
You can play with Variance till the banding disappear.

Now the grey ramp is SMOOTH without noticeable film grain or banding.
In a way, "Film Grain" works like Dithering, but at a minimal setting it's not actually creating visible grain.

I know this is a work-around but I'll be happy if the dev team will make a more professional fix to this phenomenon.
Maybe some Dithering option to smooth the banding without using tricks.

Thanks.

EDIT:
I have to mention that in MPC-HC selecting "Full Floating Point Processing" fixes this banding issue completely.
Do we have this in VLC?
Last edited by Ilya-v on 04 Sep 2013 15:16, edited 3 times in total.

Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 04 Sep 2013 13:07

BEFORE FIX:
Image

AFTER FIX:
Image

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Jean-Baptiste Kempf » 06 Sep 2013 00:30

This is a nVidia bug, no? Try to disable YUV->RGB conversions in hw.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 06 Sep 2013 08:07

Thanks for replying Jean.

No,
Same banding if using "Hardware YUV -> RGB Conversion" or not (Nvidia or VLC).
This banding also occurs in PowerDVD 13.
Only MPC-HC with selected "Full Floating Point Processing" fixes this.

Its just a side-effect of expanding fewer steps to more steps.

You can test it for yourself easily:
Play the greyscale video and move the Contrast slider.
Resulting same banding effect.
But with the Film Grain trick, the gradient remains smooth.

I think we need a dithering filter, or a higher internal bitrate calculation.

Thanks.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Jean-Baptiste Kempf » 09 Sep 2013 23:59

Try OpenGL output.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 13 Sep 2013 13:06

I've been doing some reading, apparently, this banding phenomenon is a very known problem with 16-235 to 0-255 conversion.

BUT,

MPC-HC managed to fix this with higher bit depth (more than 8-bit) processing.
Called : Full Floating Point Processing.
In the past MPC-HC had to be used with MadVR (16-bit internal processing), not anymore.
The greyscale ramp with MPC-HC looks Perfect without any plugins.



VLC team,

This is a fundamental problem !!!
Since VLC is made to play video on a full RGB PC monitor (its a computer program, right?).

If you are serious about YUV 16-235 (any video ever made) playing on full rgb (0-255) monitor without destroying the picture doing so..

THIS MUST BE FIXED.


In the mean time I'm doing my serious watching on MPC-HC.
I will also try to contact NVIDIA to implement this in the driver itself (when choosing Full (0-255) Dynamic Range).

Thanks.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Jean-Baptiste Kempf » 16 Sep 2013 14:55

Did you read my post?
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 17 Sep 2013 17:24

Of Course.
Have you read my posts?

It has nothing to do with the output, Its about the internal bit processing.

I'm with MPC-HC & MadVR now till VLC gets serious about it.



Chow.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Jean-Baptiste Kempf » 17 Sep 2013 18:48

Of Course.
And yet you did not test the OpenGL output.
It has nothing to do with the output, Its about the internal bit processing.
YUV-RGB can be done IN the output, like in the case of OpenGL output.

But you seem to know better VLC internals than we do...
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Ilya-v
Blank Cone
Blank Cone
Posts: 14
Joined: 21 Mar 2013 20:58

Re: YUV->RGB (16-235 to 0-255) BANDING FIX.

Postby Ilya-v » 17 Sep 2013 19:20

Jean, no offence please.

I have been using VLC for 5+ years now.
It was the best player till I noticed these artifacts.
And yes, I have used and tested all the possible settings (including all outputs, and advanced settings).

Including OpenGL

The banding is still there !


See this:
Image


This is what fixes the banding in MPC.

But you seem to know better VLC internals than we do...
I don't care what happens inside VLC, I care about what the final results are.
VLC, PowerDVD, and many others have banding when viewing 16-235 content on a 0-255 monitor
(Yes, after the 16-235 to 0-255 conversion with nVidia OR Software).

Moreover,
I have "discovered" that MadVR filter has "Smooth Motion" setting the makes 23.976 or 24fps movies play smoothly on my 60Hz monitor without Judder.
Also, I use a professional (High Gamut) Color Calibrated monitor (with i1 Display Pro) and MadVR allows me to use my calibration profile.
MadVR allows me to play with real gamma values like: 2.20 2.40 2.60 etc...

Thus killing 4 birds with one stone:
1. Smooth Grayscale (16-bit processing).
2. Smooth (Judder Free) playback.
3. Color Managed.
4. Real Gamma Values.


Thank you VLC team for a great (and easy) 5+ years of use.

I'm a MPC-HC guy now.


Return to “General VLC media player Troubleshooting”

Who is online

Users browsing this forum: No registered users and 108 guests