[Mesa-dev] [PATCH] Distinction between ARB and EXT dispatch table entries related to framebuffer_object.

Tomasz Lis listom at gmail.com
Tue Jul 16 11:57:26 PDT 2013


From: Tomasz Lis <tomasz.lis at intel.com>

This fix splits entries in dispatch table mechanism according to
framebuffer_object EXT and ARB specs. Different bind functions
allow further diferentiation in other calls, based on binded
type of object.

This patch is based on one created by Bartosz Zawistowski.
---
 src/mapi/glapi/gen/EXT_framebuffer_object.xml |    4 ++--
 src/mesa/main/fbobject.c                      |   14 ++++++++++++++
 src/mesa/main/fbobject.h                      |    6 ++++++
 3 files changed, 22 insertions(+), 2 deletions(-)

diff --git a/src/mapi/glapi/gen/EXT_framebuffer_object.xml b/src/mapi/glapi/gen/EXT_framebuffer_object.xml
index 85a05f6..c0232b8 100644
--- a/src/mapi/glapi/gen/EXT_framebuffer_object.xml
+++ b/src/mapi/glapi/gen/EXT_framebuffer_object.xml
@@ -78,7 +78,7 @@
 	<return type="GLboolean"/>
     </function>
 
-    <function name="BindRenderbufferEXT" alias="BindRenderbuffer">
+    <function name="BindRenderbufferEXT" offset="assign">
         <param name="target" type="GLenum"/>
         <param name="renderbuffer" type="GLuint"/>
     </function>
@@ -111,7 +111,7 @@
 	<return type="GLboolean"/>
     </function>
 
-    <function name="BindFramebufferEXT" alias="BindFramebuffer">
+    <function name="BindFramebufferEXT" offset="assign">
         <param name="target" type="GLenum"/>
         <param name="framebuffer" type="GLuint"/>
     </function>
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
index f59fdb1..a29f1ab 100644
--- a/src/mesa/main/fbobject.c
+++ b/src/mesa/main/fbobject.c
@@ -1155,6 +1155,13 @@ _mesa_BindRenderbuffer(GLenum target, GLuint renderbuffer)
 }
 
 
+void GLAPIENTRY
+_mesa_BindRenderbufferEXT(GLenum target, GLuint renderbuffer)
+{
+    _mesa_BindRenderbuffer(target, renderbuffer);
+}
+
+
 /**
  * If the given renderbuffer is anywhere attached to the framebuffer, detach
  * the renderbuffer.
@@ -2025,6 +2032,13 @@ _mesa_BindFramebuffer(GLenum target, GLuint framebuffer)
    }
 }
 
+void GLAPIENTRY
+_mesa_BindFramebufferEXT(GLenum target, GLuint framebuffer)
+{
+    _mesa_BindFramebuffer(target, framebuffer);
+}
+
+
 
 void GLAPIENTRY
 _mesa_DeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
diff --git a/src/mesa/main/fbobject.h b/src/mesa/main/fbobject.h
index 4066ea6..0a2a5cc 100644
--- a/src/mesa/main/fbobject.h
+++ b/src/mesa/main/fbobject.h
@@ -120,6 +120,9 @@ extern void GLAPIENTRY
 _mesa_BindRenderbuffer(GLenum target, GLuint renderbuffer);
 
 extern void GLAPIENTRY
+_mesa_BindRenderbufferEXT(GLenum target, GLuint renderbuffer);
+
+extern void GLAPIENTRY
 _mesa_DeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
 
 extern void GLAPIENTRY
@@ -152,6 +155,9 @@ extern void GLAPIENTRY
 _mesa_BindFramebuffer(GLenum target, GLuint framebuffer);
 
 extern void GLAPIENTRY
+_mesa_BindFramebufferEXT(GLenum target, GLuint framebuffer);
+
+extern void GLAPIENTRY
 _mesa_DeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
 
 extern void GLAPIENTRY
-- 
1.7.9.5



More information about the mesa-dev mailing list