mesa: added _mesa_DrawArrays, DrawElements, DrawRangeElements() wrappers for VBO...
authorBrian Paul <brian.paul@tungstengraphics.com>
Thu, 5 Jun 2008 18:01:00 +0000 (12:01 -0600)
committerBrian Paul <brian.paul@tungstengraphics.com>
Thu, 5 Jun 2008 18:01:33 +0000 (12:01 -0600)
src/mesa/main/varray.h
src/mesa/vbo/vbo_exec_array.c

index 3589735f68442c2b083ff1807297158d3915cf19..ba91ecf5f6a81fd6b137d97d6b39b1216372b9a0 100644 (file)
@@ -147,6 +147,20 @@ _mesa_MultiModeDrawElementsIBM( const GLenum * mode, const GLsizei * count,
                                GLsizei primcount, GLint modestride );
 
 
+
+extern void GLAPIENTRY
+_mesa_DrawArrays(GLenum mode, GLint first, GLsizei count);
+
+extern void GLAPIENTRY
+_mesa_DrawElements(GLenum mode, GLsizei count, GLenum type,
+                   const GLvoid *indices);
+
+extern void GLAPIENTRY
+_mesa_DrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count,
+                        GLenum type, const GLvoid *indices);
+
+
+
 extern void
 _mesa_init_varray( GLcontext * ctx );
 
index dbee2188eecb2bf875a5cce3eeb955222110219f..e3d2fc51cb78952fe2b061d21f0fdf9dba714360 100644 (file)
@@ -30,6 +30,7 @@
 #include "main/state.h"
 #include "main/api_validate.h"
 #include "main/api_noop.h"
+#include "main/varray.h"
 #include "glapi/dispatch.h"
 
 #include "vbo_context.h"
@@ -400,3 +401,29 @@ void vbo_exec_array_destroy( struct vbo_exec_context *exec )
 {
    /* nothing to do */
 }
+
+
+/* This API entrypoint is not ordinarily used */
+void GLAPIENTRY
+_mesa_DrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+   vbo_exec_DrawArrays(mode, first, count);
+}
+
+
+/* This API entrypoint is not ordinarily used */
+void GLAPIENTRY
+_mesa_DrawElements(GLenum mode, GLsizei count, GLenum type,
+                   const GLvoid *indices)
+{
+   vbo_exec_DrawElements(mode, count, type, indices);
+}
+
+
+/* This API entrypoint is not ordinarily used */
+void GLAPIENTRY
+_mesa_DrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count,
+                        GLenum type, const GLvoid *indices)
+{
+   vbo_exec_DrawRangeElements(mode, start, end, count, type, indices);
+}