[Mesa-dev] [PATCH] mesa: fix check for dummy renderbuffer in _mesa_FramebufferRenderbufferEXT()

Brian Paul brianp at vmware.com
Thu Apr 3 14:02:19 PDT 2014


On 04/03/2014 02:42 PM, Ian Romanick wrote:
> On 04/03/2014 12:57 AM, Chris Forbes wrote:
>> This was marked as somewhere we're deviating from the spec in order to
>> follow what nVIDIA does. Is there no longer a reason to?
>
> Well... and is it still what NVIDIA does? :)

I have the NVIDIA 325.15 driver and it still reports GL_INVALID_VALUE 
when GL_INVALID_OPERATION is expected.

-Brian


>
>> On Thu, Apr 3, 2014 at 7:30 PM, Samuel Iglesias Gonsalvez
>> <siglesias at igalia.com> wrote:
>>> According to the spec:
>>>          <renderbuffertarget> must be RENDERBUFFER and <renderbuffer>
>>>          should be set to the name of the renderbuffer object to be
>>>          attached to the framebuffer.  <renderbuffer> must be either
>>>          zero or the name of an existing renderbuffer object of type
>>>          <renderbuffertarget>, otherwise an INVALID_OPERATION error is
>>>          generated.
>>>
>>> This patch changes the previous returned GL_INVALID_VALUE to
>>> GL_INVALID_OPERATION.
>>>
>>> Bugzilla: https://urldefense.proofpoint.com/v1/url?u=https://bugs.freedesktop.org/show_bug.cgi?id%3D76894&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=lGQMzzTgII0I7jefp2FHq7WtZ%2BTLs8wadB%2BiIj9xpBY%3D%0A&m=h8%2BBbC1g2nYWv2OKvCprme4FKLqy%2FOvxYwkCmy69E4U%3D%0A&s=f3cfa1d57e6a91d96b0bf38e0c657ce9cfd28d87512041e3bb79a5d702932faa
>>>
>>> Cc: mesa-stable at lists.freedesktop.org
>>> Reviewed-by: Anuj Phogat <anuj.phogat at gmail.com>
>>> Signed-off-by: Samuel Iglesias Gonsalvez <siglesias at igalia.com>
>>> ---
>>>   src/mesa/main/fbobject.c | 3 +--
>>>   1 file changed, 1 insertion(+), 2 deletions(-)
>>>
>>> diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
>>> index 6c4f1b5..7669a0c 100644
>>> --- a/src/mesa/main/fbobject.c
>>> +++ b/src/mesa/main/fbobject.c
>>> @@ -2676,8 +2676,7 @@ _mesa_FramebufferRenderbuffer(GLenum target, GLenum attachment,
>>>           return;
>>>         }
>>>         else if (rb == &DummyRenderbuffer) {
>>> -         /* This is what NVIDIA does */
>>> -        _mesa_error(ctx, GL_INVALID_VALUE,
>>> +        _mesa_error(ctx, GL_INVALID_OPERATION,
>>>                       "glFramebufferRenderbufferEXT(renderbuffer %u)",
>>>                        renderbuffer);
>>>           return;
>>> --
>>> 1.9.1
>>>
>>> _______________________________________________
>>> mesa-dev mailing list
>>> mesa-dev at lists.freedesktop.org
>>> https://urldefense.proofpoint.com/v1/url?u=http://lists.freedesktop.org/mailman/listinfo/mesa-dev&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=lGQMzzTgII0I7jefp2FHq7WtZ%2BTLs8wadB%2BiIj9xpBY%3D%0A&m=h8%2BBbC1g2nYWv2OKvCprme4FKLqy%2FOvxYwkCmy69E4U%3D%0A&s=99f91ec41818be049a3c33a39c64cd6f70898b92564a761a33db2f084e401f36
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> https://urldefense.proofpoint.com/v1/url?u=http://lists.freedesktop.org/mailman/listinfo/mesa-dev&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=lGQMzzTgII0I7jefp2FHq7WtZ%2BTLs8wadB%2BiIj9xpBY%3D%0A&m=h8%2BBbC1g2nYWv2OKvCprme4FKLqy%2FOvxYwkCmy69E4U%3D%0A&s=99f91ec41818be049a3c33a39c64cd6f70898b92564a761a33db2f084e401f36
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://urldefense.proofpoint.com/v1/url?u=http://lists.freedesktop.org/mailman/listinfo/mesa-dev&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=lGQMzzTgII0I7jefp2FHq7WtZ%2BTLs8wadB%2BiIj9xpBY%3D%0A&m=h8%2BBbC1g2nYWv2OKvCprme4FKLqy%2FOvxYwkCmy69E4U%3D%0A&s=99f91ec41818be049a3c33a39c64cd6f70898b92564a761a33db2f084e401f36
>



More information about the mesa-dev mailing list