[Mesa-dev] [PATCH] swrast: fix active attribs with atifragshader

Miklós Máté mtmkls at gmail.com
Wed Aug 10 19:38:48 UTC 2016


On 08/04/2016 06:51 PM, Brian Paul wrote:
> On 08/04/2016 10:40 AM, Miklós Máté wrote:
>> On 07/14/2016 10:43 PM, Miklós Máté wrote:
>>> On 07/07/2016 07:11 PM, Miklós Máté wrote:
>>>> On 06/26/2016 09:48 PM, Miklós Máté wrote:
>>>>> Only include the ones that can be used by the shader.
>>>>>
>>>>> This fixes texture coordinates, which were completely wrong,
>>>>> because WPOS was included in the list of attribs. It also
>>>>> increases performance noticeably.
>>>>>
>>>>> Signed-off-by: Miklós Máté <mtmkls at gmail.com>
>>>>> ---
>>>>>   src/mesa/swrast/s_context.c | 3 ++-
>>>>>   1 file changed, 2 insertions(+), 1 deletion(-)
>>>>>
>>>>> diff --git a/src/mesa/swrast/s_context.c 
>>>>> b/src/mesa/swrast/s_context.c
>>>>> index 0a5fc7e..a63179c 100644
>>>>> --- a/src/mesa/swrast/s_context.c
>>>>> +++ b/src/mesa/swrast/s_context.c
>>>>> @@ -504,7 +504,8 @@ _swrast_update_active_attribs(struct gl_context
>>>>> *ctx)
>>>>>         attribsMask &= ~VARYING_BIT_POS; /* WPOS is always handled
>>>>> specially */
>>>>>      }
>>>>>      else if (ctx->ATIFragmentShader._Enabled) {
>>>>> -      attribsMask = ~0;  /* XXX fix me */
>>>>> +      attribsMask = VARYING_BIT_COL0 | VARYING_BIT_COL1 |
>>>>> +                    VARYING_BIT_FOGC | VARYING_BITS_TEX_ANY;
>>>>>      }
>>>>>      else {
>>>>>         /* fixed function */
>>>>
>>>> ping?
>>>>
>>> ping?
>>>
>> Can anyone please review this?
>
> I think few people know swrast and this particular extension.
>
> Looks OK to me though.
>
> Reviewed-by: Brian Paul <brianp at vmware.com>
>
Thanks for the review. If there are no objections, I need somebody to 
commit this for me, because I have no access.

MM



More information about the mesa-dev mailing list