Nicolai Hähnle <nhaeh...@gmail.com> writes:

> On 17.08.2017 18:10, Eric Anholt wrote:
>> For supporting RGB5 in hardware with A in the low bit (vc4), we need this
>> format as well.
>> ---
>>   src/mesa/main/formats.c      | 2 ++
>>   src/mesa/main/formats.csv    | 1 +
>>   src/mesa/main/formats.h      | 1 +
>>   src/mesa/main/texformat.c    | 1 +
>>   src/mesa/swrast/s_texfetch.c | 1 +
>>   5 files changed, 6 insertions(+)
>> 
>> diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c
>> index 5c29d37bb443..2fdf1c501aaf 100644
>> --- a/src/mesa/main/formats.c
>> +++ b/src/mesa/main/formats.c
>> @@ -875,6 +875,7 @@ _mesa_uncompressed_format_to_type_and_comps(mesa_format 
>> format,
>>   
>>      case MESA_FORMAT_A1B5G5R5_UNORM:
>>      case MESA_FORMAT_A1B5G5R5_UINT:
>> +   case MESA_FORMAT_X1B5G5R5_UNORM:
>>         *datatype = GL_UNSIGNED_SHORT_5_5_5_1;
>>         *comps = 4;
>>         return;
>> @@ -1999,6 +2000,7 @@ _mesa_format_matches_format_and_type(mesa_format 
>> mesa_format,
>>   
>>      case MESA_FORMAT_B4G4R4X4_UNORM:
>>      case MESA_FORMAT_B5G5R5X1_UNORM:
>> +   case MESA_FORMAT_X1B5G5R5_UNORM:
>
> I believe this should probably match the case of
>
>    format == GL_RGB && type == GL_UNSIGNED_SHORT_5_5_5_1 && !swapBytees

Good catc!.  I've added this up next to the A1B5G5R5 case.  Once I can
get an Intel CI run, I'll push.

Attachment: signature.asc
Description: PGP signature

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to