[PATCH xserver] xfree86: fix gamma compute when palette_size > 256
Michel Dänzer
michel at daenzer.net
Thu Nov 2 16:22:40 UTC 2017
On 01/11/17 11:27 AM, Yu, Qiang wrote:
>
>>> 2. the palette_size can be bigger than crtc->gamma_size, [...]
>>
>> Can it really? In Aaron's example, both have 1024 entries.
> Isn't it 2^11 for palette_size but 2^10 gamma_size?
No, palette size is 2^10 at depth 30.
>>> So according to the above understanding, I think there're two solution to the problem:
>>> 1. DDX is responsible for setting crtc->gamma_size to max hardware capable gamma
>>> CLUT size, and this patch is still needed for situation like Aaron described (11bit color
>>> but 10bit gamma CLUT) and old amdgpu KMS driver that can only support 256 gamma
>>> CLUT but need 10bit color.
>>
>> If amdgpu only programs 256 gamma CLUT entries, does the hardware
>> actually interpolate the missing entries as described by Aaron?
> Need get confirm from DCE and kernel guys.
Internal discussion revealed that the kernel driver is currently not
enabling any hardware gamma functionality at depth 30, so instead of
this patch, the Xorg driver will just not call xf86HandleColormaps in
this case.
--
Earthling Michel Dänzer | http://www.amd.com
Libre software enthusiast | Mesa and X developer
More information about the xorg-devel
mailing list