Skip to content

shaders/colorspace: exclude black pixels from peak detection

Niklas Haas requested to merge haasn/libplacebo:peak_detect_black into master

Significantly improves peak detection result on frames containing many black pixels (e.g. hardcoded black bars). In real content, truly black pixels are incredibly rare, so this is pretty safe to do.

Only requires one extra group shared atomic and some once-per-WG code. I briefly played with the idea of including this implicitly in the histogram measurement, but it was more complicated to do so and limits it to the case of histogram being enabled.

Merge request reports

Loading