[Mesa-dev] [PATCH 1/8] mesa: fill in SRGB cases in _mesa_format_matches_format_and_type

Ian Romanick idr at freedesktop.org
Fri Feb 8 20:49:12 PST 2013


On 02/08/2013 05:13 PM, Marek Olšák wrote:
> Hi Ian,
>
> 9 days have passed and I wouldn't like to delay this series any
> further. If it's okay with you, I will commit it in 2 days (or sooner).

Gak.  I completely missed your original message while I was traveling 
for FOSDEM... and it got lost in the 5 days of list traffic... and my QA 
team is away for a week for the Chinese New Year. :(

I ran it through ES3 conformance and there were no regressions in Ivy 
Bridge.  If there are regressions in other tests on other GPUs, we can 
fix them.

> Marek
>
> On Thu, Jan 31, 2013 at 9:30 PM, Marek Olšák <maraeo at gmail.com> wrote:
>> Here's the branch:
>>
>> git://people.freedesktop.org/~mareko/mesa rgbx-and-texstore
>>
>> Please let me know when it can be pushed to master.
>>
>> Marek
>>
>> On Tue, Jan 29, 2013 at 7:00 PM, Ian Romanick <idr at freedesktop.org> wrote:
>>> I like these changes, but this hits some twitchy code.  Do you have a branch
>>> somewhere that I could have my QA team test?
>>>
>>>
>>> On 01/29/2013 05:43 AM, Marek Olšák wrote:
>>>>
>>>> Texstore takes the same codepath as the corresponding linear formats.
>>>> ---
>>>>    src/mesa/main/formats.c |   10 +++++-----
>>>>    1 file changed, 5 insertions(+), 5 deletions(-)
>>>>
>>>> diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c
>>>> index 0a06200..9dab545 100644
>>>> --- a/src/mesa/main/formats.c
>>>> +++ b/src/mesa/main/formats.c
>>>> @@ -2870,6 +2870,7 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>          return GL_FALSE;
>>>>
>>>>       case MESA_FORMAT_RGBA8888:
>>>> +   case MESA_FORMAT_SRGBA8:
>>>>          if (format == GL_RGBA && type == GL_UNSIGNED_INT_8_8_8_8 &&
>>>> !swapBytes)
>>>>             return GL_TRUE;
>>>>
>>>> @@ -2917,6 +2918,7 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>          return GL_FALSE;
>>>>
>>>>       case MESA_FORMAT_ARGB8888:
>>>> +   case MESA_FORMAT_SARGB8:
>>>>          if (format == GL_BGRA && type == GL_UNSIGNED_INT_8_8_8_8_REV &&
>>>>              !swapBytes)
>>>>             return GL_TRUE;
>>>> @@ -2951,6 +2953,7 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>          return GL_FALSE;
>>>>
>>>>       case MESA_FORMAT_RGB888:
>>>> +   case MESA_FORMAT_SRGB8:
>>>>          return format == GL_BGR && type == GL_UNSIGNED_BYTE &&
>>>> littleEndian;
>>>>
>>>>       case MESA_FORMAT_BGR888:
>>>> @@ -2987,6 +2990,7 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>       case MESA_FORMAT_AL44:
>>>>          return GL_FALSE;
>>>>       case MESA_FORMAT_AL88:
>>>> +   case MESA_FORMAT_SLA8:
>>>>          return format == GL_LUMINANCE_ALPHA && type == GL_UNSIGNED_BYTE &&
>>>> littleEndian;
>>>>       case MESA_FORMAT_AL88_REV:
>>>>          return GL_FALSE;
>>>> @@ -3005,6 +3009,7 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>          return format == GL_ALPHA && type == GL_UNSIGNED_SHORT &&
>>>>             littleEndian && !swapBytes;
>>>>       case MESA_FORMAT_L8:
>>>> +   case MESA_FORMAT_SL8:
>>>>          return format == GL_LUMINANCE && type == GL_UNSIGNED_BYTE;
>>>>       case MESA_FORMAT_L16:
>>>>          return format == GL_LUMINANCE && type == GL_UNSIGNED_SHORT &&
>>>> @@ -3060,11 +3065,6 @@ _mesa_format_matches_format_and_type(gl_format
>>>> gl_format,
>>>>       case MESA_FORMAT_S8:
>>>>          return format == GL_STENCIL_INDEX && type == GL_UNSIGNED_BYTE;
>>>>
>>>> -   case MESA_FORMAT_SRGB8:
>>>> -   case MESA_FORMAT_SRGBA8:
>>>> -   case MESA_FORMAT_SARGB8:
>>>> -   case MESA_FORMAT_SL8:
>>>> -   case MESA_FORMAT_SLA8:
>>>>       case MESA_FORMAT_SRGB_DXT1:
>>>>       case MESA_FORMAT_SRGBA_DXT1:
>>>>       case MESA_FORMAT_SRGBA_DXT3:
>>>>
>>>
>



More information about the mesa-dev mailing list