@demofox heh, even if you're *extremely careful* about colorspaces and doing HDR "right" like we have, banding can creep in from everywhere.

We had an engineer spend a month and a half fighting banding on every rendering pass on the last Dragon Age. You need to dither on eeeevery colorspace conversion đŸ˜”

@jon_valdes @demofox I wonder what data types you/they used there and for what kind of data, to cause all that need for dithering? Optical vs. electrical, primaries, dynamic range...

@pq @demofox the most obvious one is applying any kind of gamma-like curve on 8bit data. Your values get stretched on one part of the curve, and you get very visible banding.

But the moment of despair comes when you realize that a simple horizontal gradient from 0 to 127 over a 4K screen will necessarily have bands that are 3840/128=30 pixels wide, and those are quite visible by a human eye. So any 8bit target will display banding on slow gradients. It's unavoidable, unless you dither/noise :)

@pq @demofox but this happens even on HDR. 10bit precision isn't magic dust that solves everything, you can still end up causing banding in a bunch of different ways

@pq @demofox
Recommendation: check out the "Bible of banding" that is the presentation on the rendering tech of Inside :)

https://blog.playdead.com/articles/inside_presentations/inside_publications.html

@pq @demofox
LOL, just checked your profile. High chance you already knew all this! Sorry for being dumb if so 😅

@jon_valdes Oh, don't worry. I always wonder if there is some insight I haven't realized yet.

I have indeed been doubting if 10 bpc is even enough for electrical BT.2100/PQ, and I've been *hoping* that 16-bit floating-point would be enough for optical display-referred data.

@demofox

@jon_valdes

Very long and slow gradients is a good point to make. Without dithering we would need the stimulus change from one code value to the next to be imperceptible when laid out as two flat fields side-by-side.

@demofox

@pq @demofox yep, exactly. And then you'd still need to make sure you don't lose precision at any point in the pipeline. It's annoyingly easy to lose precision inadvertently, just by doing color space transformations.
@jon_valdes @pq dithering so many times makes me wonder if the dither would start to become gaussian and be a different visual artifact ):