On 01/28/2013 02:43 PM, Christoph Bumiller wrote:
On 28.01.2013 23:37, Chad Versace wrote:
On 01/28/2013 02:01 PM, Christoph Bumiller wrote:
From: Christoph Bumiller <christoph.bumil...@speed.at>

Only the test of the extension enable should be relevant.
I don't think this change is correct.

So, maybe I misinterpreted the advice in the "mesa: implement
GL_ARB_texture_buffer_range v5" thread ?

In my opinion this check *should* be removed, it is driver specific and
prevents other drivers from exposing the extension in non-core contexts.
It simply doesn't seem to belong here.

It seems we had a bit of a miscommunication. We should keep these API checks. GL_ARB_texture_buffer_object has interactions with compatibility profile that are not implemented in Mesa. If any Mesa driver exposes this extension, it will be broken. We (Marek, Brian, and I) had some discussion about this back in December. We decided to just implement this extension for core profiles.

http://lists.freedesktop.org/archives/mesa-dev/2012-December/031349.html

I think there was additional discussion on #dri-devel. I can probably find the logs if that would be helpful.

For most extensions, including GL_ARB_texture_buffer_object, the Intel driver
enables the extension flags according only to hardware capabilities. That is,
the decision to enable a flag is independent of the context API. See
intel_extensions.c.

Removing this API check may incorrectly allow glTexBufferARB on Intel drivers
in a non-core GL context. I could be wrong (I don't fully understand how
GL dispatch works), but this change still makes me uncomfortable.

---
  src/mesa/main/teximage.c |    3 +--
  1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index 31a559e..5a27797 100644
--- a/src/mesa/main/teximage.c
+++ b/src/mesa/main/teximage.c
@@ -4005,8 +4005,7 @@ _mesa_TexBuffer(GLenum target, GLenum internalFormat, 
GLuint buffer)
     GET_CURRENT_CONTEXT(ctx);
     FLUSH_VERTICES(ctx, 0);

-   if (!(ctx->API == API_OPENGL_CORE &&
-         ctx->Extensions.ARB_texture_buffer_object)) {
+   if (!ctx->Extensions.ARB_texture_buffer_object) {
        _mesa_error(ctx, GL_INVALID_OPERATION, "glTexBuffer");
        return;
     }


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

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

Reply via email to