Commit a979a541 authored by Thomas Zimmermann's avatar Thomas Zimmermann
Browse files

drm/format-helper: Normalize BT.601 factors to 256



BT.601 weights RGB components by certain factors to convert the
color to grayscale. Normalize the constants to 256 instead of 10.
Allows for slightly more precise rounding. The division by 256 can
be compiled as an 8-bit shift, which might be faster on some hardware.

Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Acked-by: default avatarJavier Martinez Canillas <javierm@redhat.com>
Link: https://lore.kernel.org/r/20250603161158.423962-1-tzimmermann@suse.de
parent e2944dc6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment