Bug 76894 - Piglit/spec/EXT_framebuffer_object/fbo-bind-renderbuffer failed
Piglit/spec/EXT_framebuffer_object/fbo-bind-renderbuffer failed
Status: RESOLVED FIXED
Product: Mesa
Classification: Unclassified
Component: Mesa core
git
Other All
: medium normal
Assigned To: mesa-dev
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-04-01 09:32 UTC by Samuel Iglesias
Modified: 2014-04-17 06:08 UTC (History)
0 users

See Also:


Attachments
Patch (1.41 KB, patch)
2014-04-01 09:33 UTC, Samuel Iglesias
Details | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Samuel Iglesias 2014-04-01 09:32:31 UTC
System Environment:
--------------------------
Arch:           amd64
Platform:       Sandybridge
Mesa version:   Mesa 10.2.0-devel (git-5d76e44)

Bug detailed description:
-----------------------------

Piglit's fbo-bind-renderbuffer test failed due to receiving a different error (GL_INVALID_VALUE) from expected (GL_INVALID_OPERATION).

According to the spec:

    "<renderbuffer> must be either
    zero or the name of an existing renderbuffer object of type
    <renderbuffertarget>, otherwise an INVALID_OPERATION error is
    generated."

Errors:
Mesa: User error: GL_INVALID_VALUE in glFramebufferRenderbufferEXT(renderbuffer 2)

Output:
fbo-bind-renderbuffer: failed to generate expected error


Reproduce steps:
----------------------------
1. ./bin/fbo-bind-renderbuffer -fbo -auto
Comment 1 Samuel Iglesias 2014-04-01 09:33:59 UTC
Created attachment 96707 [details] [review]
Patch

This is the patch that changes the returned error value to GL_INVALID_OPERATION
Comment 2 Kenneth Graunke 2014-04-17 06:08:32 UTC
Fixed in master by:

commit 9927180714662456ff7b895221f67112f2567a53
Author: Samuel Iglesias Gonsalvez <siglesias@igalia.com>
Date:   Thu Apr 3 08:30:06 2014 +0200

    mesa: fix check for dummy renderbuffer in _mesa_FramebufferRenderbufferEXT()
    
    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://bugs.freedesktop.org/show_bug.cgi?id=76894
    
    Cc: mesa-stable@lists.freedesktop.org
    Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    Signed-off-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com>

Thanks for finding and fixing this!