varray.h revision 4a49301e
17117f1b4Smrg/*
27117f1b4Smrg * Mesa 3-D graphics library
34a49301eSmrg * Version:  7.6
47117f1b4Smrg *
54a49301eSmrg * Copyright (C) 1999-2008  Brian Paul   All Rights Reserved.
64a49301eSmrg * Copyright (C) 2009  VMware, Inc.  All Rights Reserved.
77117f1b4Smrg *
87117f1b4Smrg * Permission is hereby granted, free of charge, to any person obtaining a
97117f1b4Smrg * copy of this software and associated documentation files (the "Software"),
107117f1b4Smrg * to deal in the Software without restriction, including without limitation
117117f1b4Smrg * the rights to use, copy, modify, merge, publish, distribute, sublicense,
127117f1b4Smrg * and/or sell copies of the Software, and to permit persons to whom the
137117f1b4Smrg * Software is furnished to do so, subject to the following conditions:
147117f1b4Smrg *
157117f1b4Smrg * The above copyright notice and this permission notice shall be included
167117f1b4Smrg * in all copies or substantial portions of the Software.
177117f1b4Smrg *
187117f1b4Smrg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
197117f1b4Smrg * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
207117f1b4Smrg * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
217117f1b4Smrg * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
227117f1b4Smrg * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
237117f1b4Smrg * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
247117f1b4Smrg */
257117f1b4Smrg
267117f1b4Smrg
277117f1b4Smrg#ifndef VARRAY_H
287117f1b4Smrg#define VARRAY_H
297117f1b4Smrg
307117f1b4Smrg
317117f1b4Smrg#include "mtypes.h"
327117f1b4Smrg
337117f1b4Smrg#if _HAVE_FULL_GL
347117f1b4Smrg
357117f1b4Smrgextern void GLAPIENTRY
367117f1b4Smrg_mesa_VertexPointer(GLint size, GLenum type, GLsizei stride,
377117f1b4Smrg                    const GLvoid *ptr);
387117f1b4Smrg
397117f1b4Smrgextern void GLAPIENTRY
407117f1b4Smrg_mesa_UnlockArraysEXT( void );
417117f1b4Smrg
427117f1b4Smrgextern void GLAPIENTRY
437117f1b4Smrg_mesa_LockArraysEXT(GLint first, GLsizei count);
447117f1b4Smrg
457117f1b4Smrg
467117f1b4Smrgextern void GLAPIENTRY
477117f1b4Smrg_mesa_NormalPointer(GLenum type, GLsizei stride, const GLvoid *ptr);
487117f1b4Smrg
497117f1b4Smrg
507117f1b4Smrgextern void GLAPIENTRY
517117f1b4Smrg_mesa_ColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *ptr);
527117f1b4Smrg
537117f1b4Smrg
547117f1b4Smrgextern void GLAPIENTRY
557117f1b4Smrg_mesa_IndexPointer(GLenum type, GLsizei stride, const GLvoid *ptr);
567117f1b4Smrg
577117f1b4Smrg
587117f1b4Smrgextern void GLAPIENTRY
597117f1b4Smrg_mesa_TexCoordPointer(GLint size, GLenum type, GLsizei stride,
607117f1b4Smrg                      const GLvoid *ptr);
617117f1b4Smrg
627117f1b4Smrg
637117f1b4Smrgextern void GLAPIENTRY
647117f1b4Smrg_mesa_EdgeFlagPointer(GLsizei stride, const GLvoid *ptr);
657117f1b4Smrg
667117f1b4Smrg
677117f1b4Smrgextern void GLAPIENTRY
687117f1b4Smrg_mesa_VertexPointerEXT(GLint size, GLenum type, GLsizei stride,
697117f1b4Smrg                       GLsizei count, const GLvoid *ptr);
707117f1b4Smrg
717117f1b4Smrg
727117f1b4Smrgextern void GLAPIENTRY
737117f1b4Smrg_mesa_NormalPointerEXT(GLenum type, GLsizei stride, GLsizei count,
747117f1b4Smrg                       const GLvoid *ptr);
757117f1b4Smrg
767117f1b4Smrg
777117f1b4Smrgextern void GLAPIENTRY
787117f1b4Smrg_mesa_ColorPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count,
797117f1b4Smrg                      const GLvoid *ptr);
807117f1b4Smrg
817117f1b4Smrg
827117f1b4Smrgextern void GLAPIENTRY
837117f1b4Smrg_mesa_IndexPointerEXT(GLenum type, GLsizei stride, GLsizei count,
847117f1b4Smrg                      const GLvoid *ptr);
857117f1b4Smrg
867117f1b4Smrg
877117f1b4Smrgextern void GLAPIENTRY
887117f1b4Smrg_mesa_TexCoordPointerEXT(GLint size, GLenum type, GLsizei stride,
897117f1b4Smrg                         GLsizei count, const GLvoid *ptr);
907117f1b4Smrg
917117f1b4Smrg
927117f1b4Smrgextern void GLAPIENTRY
937117f1b4Smrg_mesa_EdgeFlagPointerEXT(GLsizei stride, GLsizei count, const GLboolean *ptr);
947117f1b4Smrg
957117f1b4Smrg
967117f1b4Smrgextern void GLAPIENTRY
977117f1b4Smrg_mesa_FogCoordPointerEXT(GLenum type, GLsizei stride, const GLvoid *ptr);
987117f1b4Smrg
997117f1b4Smrg
1007117f1b4Smrgextern void GLAPIENTRY
1017117f1b4Smrg_mesa_SecondaryColorPointerEXT(GLint size, GLenum type,
1027117f1b4Smrg			       GLsizei stride, const GLvoid *ptr);
1037117f1b4Smrg
1047117f1b4Smrg
105c1f859d4Smrgextern void GLAPIENTRY
106c1f859d4Smrg_mesa_PointSizePointer(GLenum type, GLsizei stride, const GLvoid *ptr);
107c1f859d4Smrg
108c1f859d4Smrg
1097117f1b4Smrgextern void GLAPIENTRY
1107117f1b4Smrg_mesa_VertexAttribPointerNV(GLuint index, GLint size, GLenum type,
1117117f1b4Smrg                            GLsizei stride, const GLvoid *pointer);
1127117f1b4Smrg
1137117f1b4Smrg
1147117f1b4Smrgextern void GLAPIENTRY
1157117f1b4Smrg_mesa_VertexAttribPointerARB(GLuint index, GLint size, GLenum type,
1167117f1b4Smrg                             GLboolean normalized, GLsizei stride,
1177117f1b4Smrg                             const GLvoid *pointer);
1187117f1b4Smrg
1197117f1b4Smrg
1207117f1b4Smrgextern void GLAPIENTRY
1217117f1b4Smrg_mesa_InterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
1227117f1b4Smrg
1237117f1b4Smrg
1247117f1b4Smrgextern void GLAPIENTRY
1257117f1b4Smrg_mesa_MultiDrawArraysEXT( GLenum mode, GLint *first,
1267117f1b4Smrg                          GLsizei *count, GLsizei primcount );
1277117f1b4Smrg
1287117f1b4Smrgextern void GLAPIENTRY
1297117f1b4Smrg_mesa_MultiDrawElementsEXT( GLenum mode, const GLsizei *count, GLenum type,
1307117f1b4Smrg                            const GLvoid **indices, GLsizei primcount );
1317117f1b4Smrg
1324a49301eSmrgextern void GLAPIENTRY
1334a49301eSmrg_mesa_MultiDrawElementsBaseVertex( GLenum mode,
1344a49301eSmrg				   const GLsizei *count, GLenum type,
1354a49301eSmrg				   const GLvoid **indices, GLsizei primcount,
1364a49301eSmrg				   const GLint *basevertex);
1377117f1b4Smrg
1387117f1b4Smrgextern void GLAPIENTRY
1397117f1b4Smrg_mesa_MultiModeDrawArraysIBM( const GLenum * mode, const GLint * first,
1407117f1b4Smrg			      const GLsizei * count,
1417117f1b4Smrg			      GLsizei primcount, GLint modestride );
1427117f1b4Smrg
1437117f1b4Smrg
1447117f1b4Smrgextern void GLAPIENTRY
1457117f1b4Smrg_mesa_MultiModeDrawElementsIBM( const GLenum * mode, const GLsizei * count,
1467117f1b4Smrg				GLenum type, const GLvoid * const * indices,
1477117f1b4Smrg				GLsizei primcount, GLint modestride );
1487117f1b4Smrg
149c1f859d4Smrgextern void GLAPIENTRY
150c1f859d4Smrg_mesa_LockArraysEXT(GLint first, GLsizei count);
151c1f859d4Smrg
152c1f859d4Smrgextern void GLAPIENTRY
153c1f859d4Smrg_mesa_UnlockArraysEXT( void );
1547117f1b4Smrg
1554a49301eSmrg
1564a49301eSmrgextern void GLAPIENTRY
1574a49301eSmrg_mesa_DrawArrays(GLenum mode, GLint first, GLsizei count);
1584a49301eSmrg
1594a49301eSmrgextern void GLAPIENTRY
1604a49301eSmrg_mesa_DrawElements(GLenum mode, GLsizei count, GLenum type,
1614a49301eSmrg                   const GLvoid *indices);
1624a49301eSmrg
1634a49301eSmrgextern void GLAPIENTRY
1644a49301eSmrg_mesa_DrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count,
1654a49301eSmrg                        GLenum type, const GLvoid *indices);
1664a49301eSmrg
1674a49301eSmrgextern void GLAPIENTRY
1684a49301eSmrg_mesa_DrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type,
1694a49301eSmrg			     const GLvoid *indices, GLint basevertex);
1704a49301eSmrg
1714a49301eSmrgextern void GLAPIENTRY
1724a49301eSmrg_mesa_DrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end,
1734a49301eSmrg				  GLsizei count, GLenum type,
1744a49301eSmrg				  const GLvoid *indices,
1754a49301eSmrg				  GLint basevertex);
1764a49301eSmrg
1774a49301eSmrg
1784a49301eSmrgextern void
1794a49301eSmrg_mesa_copy_client_array(GLcontext *ctx,
1804a49301eSmrg                        struct gl_client_array *dst,
1814a49301eSmrg                        struct gl_client_array *src);
1824a49301eSmrg
1834a49301eSmrg
1844a49301eSmrgextern void
1854a49301eSmrg_mesa_print_arrays(GLcontext *ctx);
1864a49301eSmrg
1877117f1b4Smrgextern void
1887117f1b4Smrg_mesa_init_varray( GLcontext * ctx );
1897117f1b4Smrg
1904a49301eSmrgextern void
1914a49301eSmrg_mesa_free_varray_data(GLcontext *ctx);
1924a49301eSmrg
1937117f1b4Smrg#else
1947117f1b4Smrg
1957117f1b4Smrg/** No-op */
1967117f1b4Smrg#define _mesa_init_varray( c )  ((void)0)
1974a49301eSmrg#define _mesa_free_varray_data( c )  ((void)0)
1987117f1b4Smrg
1997117f1b4Smrg#endif
2007117f1b4Smrg
2017117f1b4Smrg#endif
202