Re: [PATCH v2 11/12] drm/vkms: add script to create optimized LUTs for color curves

From: Louis Chauvet

Date: Wed Nov 25 2026 - 10:51:18 EST




On 11/6/26 21:18, Leandro Ribeiro wrote:
Add a Python script to generate u16 LUTs for VKMS color transfer
functions while minimizing interpolation and quantization errors.

The script compares different LUT generation strategies and uses greedy
subdivision to generate optimized LUTs for the supported transfer
functions.

It also outputs the generated LUTs in a format ready to be added to
vkms_luts.c.

v2:
- Address feedback from Sashiko bot: conditionally plot, to avoid issues
on headless systems.
https://sashiko.dev/#/patchset/20260804203351.148521-1-leandro.ribeiro@xxxxxxxxxxxxx?part=10

Reviewed-by: Robert Mader <robert.mader@xxxxxxxxxxxxx>
Tested-by: Robert Mader <robert.mader@xxxxxxxxxxxxx>
Signed-off-by: Leandro Ribeiro <leandro.ribeiro@xxxxxxxxxxxxx>
Reviewed-by: Louis Chauvet <louis.chauvet@xxxxxxxxxxx>