GLboolean
glAreTexturesResident_s(n, textures, residences)
  GLsizei n
  SV *textures
  SV *residences
CODE:
  const GLuint *textures_s = EL(textures, sizeof(GLuint)*n);
  GLboolean *residences_s = EL(residences, sizeof(GLboolean)*n);
  RETVAL = glAreTexturesResident(n, textures_s, residences_s);
OUTPUT:
  RETVAL

void
glClipPlane_s(plane, equation)
  GLenum plane
  SV *equation
CODE:
  const GLdouble *equation_s = EL(equation, sizeof(GLdouble)*4);
  glClipPlane(plane, equation_s);

void
glColor3bv_s(v)
  SV *v
CODE:
  const GLbyte *v_s = EL(v, sizeof(GLbyte)*3);
  glColor3bv(v_s);

void
glColor3dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glColor3dv(v_s);

void
glColor3fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glColor3fv(v_s);

void
glColor3iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glColor3iv(v_s);

void
glColor3sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glColor3sv(v_s);

void
glColor3ubv_s(v)
  SV *v
CODE:
  const GLubyte *v_s = EL(v, sizeof(GLubyte)*3);
  glColor3ubv(v_s);

void
glColor3uiv_s(v)
  SV *v
CODE:
  const GLuint *v_s = EL(v, sizeof(GLuint)*3);
  glColor3uiv(v_s);

void
glColor3usv_s(v)
  SV *v
CODE:
  const GLushort *v_s = EL(v, sizeof(GLushort)*3);
  glColor3usv(v_s);

void
glColor4bv_s(v)
  SV *v
CODE:
  const GLbyte *v_s = EL(v, sizeof(GLbyte)*4);
  glColor4bv(v_s);

void
glColor4dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glColor4dv(v_s);

void
glColor4fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glColor4fv(v_s);

void
glColor4iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glColor4iv(v_s);

void
glColor4sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glColor4sv(v_s);

void
glColor4ubv_s(v)
  SV *v
CODE:
  const GLubyte *v_s = EL(v, sizeof(GLubyte)*4);
  glColor4ubv(v_s);

void
glColor4uiv_s(v)
  SV *v
CODE:
  const GLuint *v_s = EL(v, sizeof(GLuint)*4);
  glColor4uiv(v_s);

void
glColor4usv_s(v)
  SV *v
CODE:
  const GLushort *v_s = EL(v, sizeof(GLushort)*4);
  glColor4usv(v_s);

#ifdef GL_VERSION_1_5

void
glDeleteBuffers_s(n, buffers)
  GLsizei n
  SV *buffers
INIT:
  loadProc(glDeleteBuffers,"glDeleteBuffers");
CODE:
  const GLuint* buffers_s = EL(buffers, sizeof(GLuint)*n);
  glDeleteBuffers(n, buffers_s);

#endif

#ifdef GL_ARB_vertex_buffer_object

void
glDeleteBuffersARB_s(n, buffers)
  GLsizei n
  SV *buffers
INIT:
  loadProc(glDeleteBuffersARB,"glDeleteBuffersARB");
CODE:
  const GLuint* buffers_s = EL(buffers, sizeof(GLuint)*n);
  glDeleteBuffersARB(n, buffers_s);

#endif

#ifdef GL_ARB_framebuffer_object

void
glDeleteFramebuffers_s(n, framebuffers)
  GLsizei n
  SV *framebuffers
INIT:
  loadProc(glDeleteFramebuffers,"glDeleteFramebuffers");
CODE:
  const GLuint* framebuffers_s = EL(framebuffers, sizeof(GLuint)*n);
  glDeleteFramebuffers(n, framebuffers_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glDeleteFramebuffersEXT_s(n, framebuffers)
  GLsizei n
  SV *framebuffers
INIT:
  loadProc(glDeleteFramebuffersEXT,"glDeleteFramebuffersEXT");
CODE:
  const GLuint* framebuffers_s = EL(framebuffers, sizeof(GLuint)*n);
  glDeleteFramebuffersEXT(n, framebuffers_s);

#endif

#ifdef GL_ARB_vertex_program

void
glDeleteProgramsARB_s(n, programs)
  GLsizei n
  SV *programs
INIT:
  loadProc(glDeleteProgramsARB,"glDeleteProgramsARB");
CODE:
  const GLuint* programs_s = EL(programs, sizeof(GLuint)*n);
  glDeleteProgramsARB(n, programs_s);

#endif

#ifdef GL_ARB_framebuffer_object

void
glDeleteRenderbuffers_s(n, renderbuffers)
  GLsizei n
  SV *renderbuffers
INIT:
  loadProc(glDeleteRenderbuffers,"glDeleteRenderbuffers");
CODE:
  const GLuint* renderbuffers_s = EL(renderbuffers, sizeof(GLuint)*n);
  glDeleteRenderbuffers(n, renderbuffers_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glDeleteRenderbuffersEXT_s(n, renderbuffers)
  GLsizei n
  SV *renderbuffers
INIT:
  loadProc(glDeleteRenderbuffersEXT,"glDeleteRenderbuffersEXT");
CODE:
  const GLuint* renderbuffers_s = EL(renderbuffers, sizeof(GLuint)*n);
  glDeleteRenderbuffersEXT(n, renderbuffers_s);

#endif

void
glDeleteTextures_s(n, textures)
  GLsizei n
  SV *textures
CODE:
  const GLuint *textures_s = EL(textures, sizeof(GLuint)*n);
  glDeleteTextures(n, textures_s);

#ifdef GL_VERSION_2_0

void
glDrawBuffers_s(n, bufs)
  GLsizei n
  SV *bufs
INIT:
  loadProc(glDrawBuffers,"glDrawBuffers");
CODE:
  const GLenum* bufs_s = EL(bufs, sizeof(GLenum)*n);
  glDrawBuffers(n, bufs_s);

#endif

#ifdef GL_ARB_draw_buffers

void
glDrawBuffersARB_s(n, bufs)
  GLsizei n
  SV *bufs
INIT:
  loadProc(glDrawBuffersARB,"glDrawBuffersARB");
CODE:
  const GLenum* bufs_s = EL(bufs, sizeof(GLenum)*n);
  glDrawBuffersARB(n, bufs_s);

#endif

void
glFogfv_s(pname, params)
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_FogParameter_count(pname);
  if (pname_count < 0) croak("Unknown FogParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glFogfv(pname, params_s);

void
glFogiv_s(pname, params)
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_FogParameter_count(pname);
  if (pname_count < 0) croak("Unknown FogParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glFogiv(pname, params_s);

#ifdef GL_VERSION_1_5

void
glGenBuffers_s(n, buffers)
  GLsizei n
  SV *buffers
INIT:
  loadProc(glGenBuffers,"glGenBuffers");
CODE:
  GLuint* buffers_s = EL(buffers, sizeof(GLuint)*n);
  glGenBuffers(n, buffers_s);

#endif

#ifdef GL_ARB_vertex_buffer_object

void
glGenBuffersARB_s(n, buffers)
  GLsizei n
  SV *buffers
INIT:
  loadProc(glGenBuffersARB,"glGenBuffersARB");
CODE:
  GLuint* buffers_s = EL(buffers, sizeof(GLuint)*n);
  glGenBuffersARB(n, buffers_s);

#endif

#ifdef GL_ARB_framebuffer_object

void
glGenFramebuffers_s(n, framebuffers)
  GLsizei n
  SV *framebuffers
INIT:
  loadProc(glGenFramebuffers,"glGenFramebuffers");
CODE:
  GLuint* framebuffers_s = EL(framebuffers, sizeof(GLuint)*n);
  glGenFramebuffers(n, framebuffers_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glGenFramebuffersEXT_s(n, framebuffers)
  GLsizei n
  SV *framebuffers
INIT:
  loadProc(glGenFramebuffersEXT,"glGenFramebuffersEXT");
CODE:
  GLuint* framebuffers_s = EL(framebuffers, sizeof(GLuint)*n);
  glGenFramebuffersEXT(n, framebuffers_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGenProgramsARB_s(n, programs)
  GLsizei n
  SV *programs
INIT:
  loadProc(glGenProgramsARB,"glGenProgramsARB");
CODE:
  GLuint* programs_s = EL(programs, sizeof(GLuint)*n);
  glGenProgramsARB(n, programs_s);

#endif

#ifdef GL_ARB_framebuffer_object

void
glGenRenderbuffers_s(n, renderbuffers)
  GLsizei n
  SV *renderbuffers
INIT:
  loadProc(glGenRenderbuffers,"glGenRenderbuffers");
CODE:
  GLuint* renderbuffers_s = EL(renderbuffers, sizeof(GLuint)*n);
  glGenRenderbuffers(n, renderbuffers_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glGenRenderbuffersEXT_s(n, renderbuffers)
  GLsizei n
  SV *renderbuffers
INIT:
  loadProc(glGenRenderbuffersEXT,"glGenRenderbuffersEXT");
CODE:
  GLuint* renderbuffers_s = EL(renderbuffers, sizeof(GLuint)*n);
  glGenRenderbuffersEXT(n, renderbuffers_s);

#endif

void
glGenTextures_s(n, textures)
  GLsizei n
  SV *textures
CODE:
  GLuint *textures_s = EL(textures, sizeof(GLuint)*n);
  glGenTextures(n, textures_s);

#ifdef GL_ARB_vertex_shader

void
glGetActiveAttribARB_s(program, index, bufSize, length, size, type, name)
  GLhandleARB program
  GLuint index
  GLsizei bufSize
  SV *length
  SV *size
  SV *type
  SV *name
INIT:
  loadProc(glGetActiveAttribARB,"glGetActiveAttribARB");
CODE:
  GLsizei* length_s = EL(length, sizeof(GLsizei)*1);
  GLint *size_s = EL(size, sizeof(GLint)*1);
  GLenum *type_s = EL(type, sizeof(GLenum)*1);
  GLcharARB *name_s = EL(name, sizeof(GLcharARB)*bufSize);
  glGetActiveAttribARB(program, index, bufSize, length_s, size_s, type_s, name_s);

#endif

#ifdef GL_ARB_shader_objects

void
glGetActiveUniformARB_s(program, index, bufSize, length, size, type, name)
  GLhandleARB program
  GLuint index
  GLsizei bufSize
  SV *length
  SV *size
  SV *type
  SV *name
INIT:
  loadProc(glGetActiveUniformARB,"glGetActiveUniformARB");
CODE:
  GLsizei* length_s = EL(length, sizeof(GLsizei)*1);
  GLint *size_s = EL(size, sizeof(GLint)*1);
  GLenum *type_s = EL(type, sizeof(GLenum)*1);
  GLcharARB *name_s = EL(name, sizeof(GLcharARB)*bufSize);
  glGetActiveUniformARB(program, index, bufSize, length_s, size_s, type_s, name_s);

#endif

void
glGetBooleanv_s(pname, data)
  GLenum pname
  SV *data
CODE:
  int pname_count = gl_GetPName_count(pname);
  if (pname_count < 0) croak("Unknown GetPName parameter");
  GLboolean *data_s = EL(data, sizeof(GLboolean)*pname_count);
  glGetBooleanv(pname, data_s);

#ifdef GL_VERSION_1_5

void
glGetBufferParameteriv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
INIT:
  loadProc(glGetBufferParameteriv,"glGetBufferParameteriv");
CODE:
  int pname_count = gl_BufferPNameARB_count(pname);
  if (pname_count < 0) croak("Unknown BufferPNameARB parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetBufferParameteriv(target, pname, params_s);

#endif

#ifdef GL_ARB_vertex_buffer_object

void
glGetBufferParameterivARB_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
INIT:
  loadProc(glGetBufferParameterivARB,"glGetBufferParameterivARB");
CODE:
  int pname_count = gl_BufferPNameARB_count(pname);
  if (pname_count < 0) croak("Unknown BufferPNameARB parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetBufferParameterivARB(target, pname, params_s);

#endif

void
glGetClipPlane_s(plane, equation)
  GLenum plane
  SV *equation
CODE:
  GLdouble *equation_s = EL(equation, sizeof(GLdouble)*4);
  glGetClipPlane(plane, equation_s);

void
glGetDoublev_s(pname, data)
  GLenum pname
  SV *data
CODE:
  int pname_count = gl_GetPName_count(pname);
  if (pname_count < 0) croak("Unknown GetPName parameter");
  GLdouble *data_s = EL(data, sizeof(GLdouble)*pname_count);
  glGetDoublev(pname, data_s);

void
glGetFloatv_s(pname, data)
  GLenum pname
  SV *data
CODE:
  int pname_count = gl_GetPName_count(pname);
  if (pname_count < 0) croak("Unknown GetPName parameter");
  GLfloat *data_s = EL(data, sizeof(GLfloat)*pname_count);
  glGetFloatv(pname, data_s);

#ifdef GL_ARB_framebuffer_object

void
glGetFramebufferAttachmentParameteriv_s(target, attachment, pname, params)
  GLenum target
  GLenum attachment
  GLenum pname
  SV *params
INIT:
  loadProc(glGetFramebufferAttachmentParameteriv,"glGetFramebufferAttachmentParameteriv");
CODE:
  int pname_count = gl_FramebufferAttachmentParameterName_count(pname);
  if (pname_count < 0) croak("Unknown FramebufferAttachmentParameterName parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetFramebufferAttachmentParameteriv(target, attachment, pname, params_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glGetFramebufferAttachmentParameterivEXT_s(target, attachment, pname, params)
  GLenum target
  GLenum attachment
  GLenum pname
  SV *params
INIT:
  loadProc(glGetFramebufferAttachmentParameterivEXT,"glGetFramebufferAttachmentParameterivEXT");
CODE:
  int pname_count = gl_FramebufferAttachmentParameterName_count(pname);
  if (pname_count < 0) croak("Unknown FramebufferAttachmentParameterName parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetFramebufferAttachmentParameterivEXT(target, attachment, pname, params_s);

#endif

void
glGetIntegerv_s(pname, data)
  GLenum pname
  SV *data
CODE:
  int pname_count = gl_GetPName_count(pname);
  if (pname_count < 0) croak("Unknown GetPName parameter");
  GLint *data_s = EL(data, sizeof(GLint)*pname_count);
  glGetIntegerv(pname, data_s);

void
glGetLightfv_s(light, pname, params)
  GLenum light
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetLightfv(light, pname, params_s);

void
glGetLightiv_s(light, pname, params)
  GLenum light
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetLightiv(light, pname, params_s);

void
glGetMaterialfv_s(face, pname, params)
  GLenum face
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_MaterialParameter_count(pname);
  if (pname_count < 0) croak("Unknown MaterialParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetMaterialfv(face, pname, params_s);

void
glGetMaterialiv_s(face, pname, params)
  GLenum face
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_MaterialParameter_count(pname);
  if (pname_count < 0) croak("Unknown MaterialParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetMaterialiv(face, pname, params_s);

#ifdef GL_ARB_vertex_program

void
glGetProgramEnvParameterdvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glGetProgramEnvParameterdvARB,"glGetProgramEnvParameterdvARB");
CODE:
  GLdouble* params_s = EL(params, sizeof(GLdouble)*4);
  glGetProgramEnvParameterdvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetProgramEnvParameterfvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glGetProgramEnvParameterfvARB,"glGetProgramEnvParameterfvARB");
CODE:
  GLfloat* params_s = EL(params, sizeof(GLfloat)*4);
  glGetProgramEnvParameterfvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetProgramLocalParameterdvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glGetProgramLocalParameterdvARB,"glGetProgramLocalParameterdvARB");
CODE:
  GLdouble* params_s = EL(params, sizeof(GLdouble)*4);
  glGetProgramLocalParameterdvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetProgramLocalParameterfvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glGetProgramLocalParameterfvARB,"glGetProgramLocalParameterfvARB");
CODE:
  GLfloat* params_s = EL(params, sizeof(GLfloat)*4);
  glGetProgramLocalParameterfvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetProgramivARB_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
INIT:
  loadProc(glGetProgramivARB,"glGetProgramivARB");
CODE:
  GLint* params_s = EL(params, sizeof(GLint)*1);
  glGetProgramivARB(target, pname, params_s);

#endif

#ifdef GL_ARB_framebuffer_object

void
glGetRenderbufferParameteriv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
INIT:
  loadProc(glGetRenderbufferParameteriv,"glGetRenderbufferParameteriv");
CODE:
  int pname_count = gl_RenderbufferParameterName_count(pname);
  if (pname_count < 0) croak("Unknown RenderbufferParameterName parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetRenderbufferParameteriv(target, pname, params_s);

#endif

#ifdef GL_EXT_framebuffer_object

void
glGetRenderbufferParameterivEXT_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
INIT:
  loadProc(glGetRenderbufferParameterivEXT,"glGetRenderbufferParameterivEXT");
CODE:
  int pname_count = gl_RenderbufferParameterName_count(pname);
  if (pname_count < 0) croak("Unknown RenderbufferParameterName parameter");
  GLint* params_s = EL(params, sizeof(GLint)*pname_count);
  glGetRenderbufferParameterivEXT(target, pname, params_s);

#endif

void
glGetTexEnvfv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureEnvParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureEnvParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetTexEnvfv(target, pname, params_s);

void
glGetTexEnviv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureEnvParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureEnvParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetTexEnviv(target, pname, params_s);

void
glGetTexGendv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  GLdouble *params_s = EL(params, sizeof(GLdouble)*pname_count);
  glGetTexGendv(coord, pname, params_s);

void
glGetTexGenfv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetTexGenfv(coord, pname, params_s);

void
glGetTexGeniv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetTexGeniv(coord, pname, params_s);

void
glGetTexLevelParameterfv_s(target, level, pname, params)
  GLenum target
  GLint level
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_GetTextureParameter_count(pname);
  if (pname_count < 0) croak("Unknown GetTextureParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetTexLevelParameterfv(target, level, pname, params_s);

void
glGetTexLevelParameteriv_s(target, level, pname, params)
  GLenum target
  GLint level
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_GetTextureParameter_count(pname);
  if (pname_count < 0) croak("Unknown GetTextureParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetTexLevelParameteriv(target, level, pname, params_s);

void
glGetTexParameterfv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_GetTextureParameter_count(pname);
  if (pname_count < 0) croak("Unknown GetTextureParameter parameter");
  GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glGetTexParameterfv(target, pname, params_s);

void
glGetTexParameteriv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_GetTextureParameter_count(pname);
  if (pname_count < 0) croak("Unknown GetTextureParameter parameter");
  GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glGetTexParameteriv(target, pname, params_s);

#ifdef GL_ARB_vertex_program

void
glGetVertexAttribdvARB_s(index, pname, params)
  GLuint index
  GLenum pname
  SV *params
INIT:
  loadProc(glGetVertexAttribdvARB,"glGetVertexAttribdvARB");
CODE:
  GLdouble* params_s = EL(params, sizeof(GLdouble)*4);
  glGetVertexAttribdvARB(index, pname, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetVertexAttribfvARB_s(index, pname, params)
  GLuint index
  GLenum pname
  SV *params
INIT:
  loadProc(glGetVertexAttribfvARB,"glGetVertexAttribfvARB");
CODE:
  GLfloat* params_s = EL(params, sizeof(GLfloat)*4);
  glGetVertexAttribfvARB(index, pname, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glGetVertexAttribivARB_s(index, pname, params)
  GLuint index
  GLenum pname
  SV *params
INIT:
  loadProc(glGetVertexAttribivARB,"glGetVertexAttribivARB");
CODE:
  GLint* params_s = EL(params, sizeof(GLint)*4);
  glGetVertexAttribivARB(index, pname, params_s);

#endif

void
glLightModelfv_s(pname, params)
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightModelParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightModelParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glLightModelfv(pname, params_s);

void
glLightModeliv_s(pname, params)
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightModelParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightModelParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glLightModeliv(pname, params_s);

void
glLightfv_s(light, pname, params)
  GLenum light
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glLightfv(light, pname, params_s);

void
glLightiv_s(light, pname, params)
  GLenum light
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_LightParameter_count(pname);
  if (pname_count < 0) croak("Unknown LightParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glLightiv(light, pname, params_s);

void
glLoadMatrixd_s(m)
  SV *m
CODE:
  const GLdouble *m_s = EL(m, sizeof(GLdouble)*16);
  glLoadMatrixd(m_s);

void
glLoadMatrixf_s(m)
  SV *m
CODE:
  const GLfloat *m_s = EL(m, sizeof(GLfloat)*16);
  glLoadMatrixf(m_s);

void
glMaterialfv_s(face, pname, params)
  GLenum face
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_MaterialParameter_count(pname);
  if (pname_count < 0) croak("Unknown MaterialParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glMaterialfv(face, pname, params_s);

void
glMaterialiv_s(face, pname, params)
  GLenum face
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_MaterialParameter_count(pname);
  if (pname_count < 0) croak("Unknown MaterialParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glMaterialiv(face, pname, params_s);

#ifdef GL_VERSION_1_3

void
glMultiTexCoord1dv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1dv,"glMultiTexCoord1dv");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*1);
  glMultiTexCoord1dv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord1dvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1dvARB,"glMultiTexCoord1dvARB");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*1);
  glMultiTexCoord1dvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord1fv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1fv,"glMultiTexCoord1fv");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*1);
  glMultiTexCoord1fv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord1fvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1fvARB,"glMultiTexCoord1fvARB");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*1);
  glMultiTexCoord1fvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord1iv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1iv,"glMultiTexCoord1iv");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*1);
  glMultiTexCoord1iv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord1ivARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1ivARB,"glMultiTexCoord1ivARB");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*1);
  glMultiTexCoord1ivARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord1sv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1sv,"glMultiTexCoord1sv");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*1);
  glMultiTexCoord1sv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord1svARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord1svARB,"glMultiTexCoord1svARB");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*1);
  glMultiTexCoord1svARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord2dv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2dv,"glMultiTexCoord2dv");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*2);
  glMultiTexCoord2dv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord2dvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2dvARB,"glMultiTexCoord2dvARB");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*2);
  glMultiTexCoord2dvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord2fv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2fv,"glMultiTexCoord2fv");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*2);
  glMultiTexCoord2fv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord2fvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2fvARB,"glMultiTexCoord2fvARB");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*2);
  glMultiTexCoord2fvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord2iv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2iv,"glMultiTexCoord2iv");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*2);
  glMultiTexCoord2iv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord2ivARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2ivARB,"glMultiTexCoord2ivARB");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*2);
  glMultiTexCoord2ivARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord2sv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2sv,"glMultiTexCoord2sv");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*2);
  glMultiTexCoord2sv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord2svARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord2svARB,"glMultiTexCoord2svARB");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*2);
  glMultiTexCoord2svARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord3dv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3dv,"glMultiTexCoord3dv");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glMultiTexCoord3dv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord3dvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3dvARB,"glMultiTexCoord3dvARB");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glMultiTexCoord3dvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord3fv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3fv,"glMultiTexCoord3fv");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glMultiTexCoord3fv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord3fvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3fvARB,"glMultiTexCoord3fvARB");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glMultiTexCoord3fvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord3iv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3iv,"glMultiTexCoord3iv");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glMultiTexCoord3iv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord3ivARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3ivARB,"glMultiTexCoord3ivARB");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glMultiTexCoord3ivARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord3sv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3sv,"glMultiTexCoord3sv");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glMultiTexCoord3sv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord3svARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord3svARB,"glMultiTexCoord3svARB");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glMultiTexCoord3svARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord4dv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4dv,"glMultiTexCoord4dv");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glMultiTexCoord4dv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord4dvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4dvARB,"glMultiTexCoord4dvARB");
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glMultiTexCoord4dvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord4fv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4fv,"glMultiTexCoord4fv");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glMultiTexCoord4fv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord4fvARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4fvARB,"glMultiTexCoord4fvARB");
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glMultiTexCoord4fvARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord4iv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4iv,"glMultiTexCoord4iv");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glMultiTexCoord4iv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord4ivARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4ivARB,"glMultiTexCoord4ivARB");
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glMultiTexCoord4ivARB(target, v_s);

#endif

#ifdef GL_VERSION_1_3

void
glMultiTexCoord4sv_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4sv,"glMultiTexCoord4sv");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glMultiTexCoord4sv(target, v_s);

#endif

#ifdef GL_ARB_multitexture

void
glMultiTexCoord4svARB_s(target, v)
  GLenum target
  SV *v
INIT:
  loadProc(glMultiTexCoord4svARB,"glMultiTexCoord4svARB");
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glMultiTexCoord4svARB(target, v_s);

#endif

void
glNormal3bv_s(v)
  SV *v
CODE:
  const GLbyte *v_s = EL(v, sizeof(GLbyte)*3);
  glNormal3bv(v_s);

void
glNormal3dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glNormal3dv(v_s);

void
glNormal3fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glNormal3fv(v_s);

void
glNormal3iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glNormal3iv(v_s);

void
glNormal3sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glNormal3sv(v_s);

void
glPixelMapfv_s(map, mapsize, values)
  GLenum map
  GLsizei mapsize
  SV *values
CODE:
  const GLfloat *values_s = EL(values, sizeof(GLfloat)*mapsize);
  glPixelMapfv(map, mapsize, values_s);

void
glPixelMapuiv_s(map, mapsize, values)
  GLenum map
  GLsizei mapsize
  SV *values
CODE:
  const GLuint *values_s = EL(values, sizeof(GLuint)*mapsize);
  glPixelMapuiv(map, mapsize, values_s);

void
glPixelMapusv_s(map, mapsize, values)
  GLenum map
  GLsizei mapsize
  SV *values
CODE:
  const GLushort *values_s = EL(values, sizeof(GLushort)*mapsize);
  glPixelMapusv(map, mapsize, values_s);

#ifdef GL_ARB_point_parameters

void
glPointParameterfvARB_s(pname, params)
  GLenum pname
  SV *params
INIT:
  loadProc(glPointParameterfvARB,"glPointParameterfvARB");
CODE:
  int pname_count = gl_PointParameterNameARB_count(pname);
  if (pname_count < 0) croak("Unknown PointParameterNameARB parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glPointParameterfvARB(pname, params_s);

#endif

void
glPrioritizeTextures_s(n, textures, priorities)
  GLsizei n
  SV *textures
  SV *priorities
CODE:
  const GLuint *textures_s = EL(textures, sizeof(GLuint)*n);
  const GLclampf *priorities_s = EL(priorities, sizeof(GLclampf)*n);
  glPrioritizeTextures(n, textures_s, priorities_s);

#ifdef GL_ARB_vertex_program

void
glProgramEnvParameter4dvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glProgramEnvParameter4dvARB,"glProgramEnvParameter4dvARB");
CODE:
  const GLdouble* params_s = EL(params, sizeof(GLdouble)*4);
  glProgramEnvParameter4dvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glProgramEnvParameter4fvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glProgramEnvParameter4fvARB,"glProgramEnvParameter4fvARB");
CODE:
  const GLfloat* params_s = EL(params, sizeof(GLfloat)*4);
  glProgramEnvParameter4fvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glProgramLocalParameter4dvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glProgramLocalParameter4dvARB,"glProgramLocalParameter4dvARB");
CODE:
  const GLdouble* params_s = EL(params, sizeof(GLdouble)*4);
  glProgramLocalParameter4dvARB(target, index, params_s);

#endif

#ifdef GL_ARB_vertex_program

void
glProgramLocalParameter4fvARB_s(target, index, params)
  GLenum target
  GLuint index
  SV *params
INIT:
  loadProc(glProgramLocalParameter4fvARB,"glProgramLocalParameter4fvARB");
CODE:
  const GLfloat* params_s = EL(params, sizeof(GLfloat)*4);
  glProgramLocalParameter4fvARB(target, index, params_s);

#endif

void
glRasterPos2dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*2);
  glRasterPos2dv(v_s);

void
glRasterPos2fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*2);
  glRasterPos2fv(v_s);

void
glRasterPos2iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*2);
  glRasterPos2iv(v_s);

void
glRasterPos2sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*2);
  glRasterPos2sv(v_s);

void
glRasterPos3dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glRasterPos3dv(v_s);

void
glRasterPos3fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glRasterPos3fv(v_s);

void
glRasterPos3iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glRasterPos3iv(v_s);

void
glRasterPos3sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glRasterPos3sv(v_s);

void
glRasterPos4dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glRasterPos4dv(v_s);

void
glRasterPos4fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glRasterPos4fv(v_s);

void
glRasterPos4iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glRasterPos4iv(v_s);

void
glRasterPos4sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glRasterPos4sv(v_s);

void
glRectdv_s(v1, v2)
  SV *v1
  SV *v2
CODE:
  const GLdouble *v1_s = EL(v1, sizeof(GLdouble)*2);
  const GLdouble *v2_s = EL(v2, sizeof(GLdouble)*2);
  glRectdv(v1_s, v2_s);

void
glRectfv_s(v1, v2)
  SV *v1
  SV *v2
CODE:
  const GLfloat *v1_s = EL(v1, sizeof(GLfloat)*2);
  const GLfloat *v2_s = EL(v2, sizeof(GLfloat)*2);
  glRectfv(v1_s, v2_s);

void
glRectiv_s(v1, v2)
  SV *v1
  SV *v2
CODE:
  const GLint *v1_s = EL(v1, sizeof(GLint)*2);
  const GLint *v2_s = EL(v2, sizeof(GLint)*2);
  glRectiv(v1_s, v2_s);

void
glRectsv_s(v1, v2)
  SV *v1
  SV *v2
CODE:
  const GLshort *v1_s = EL(v1, sizeof(GLshort)*2);
  const GLshort *v2_s = EL(v2, sizeof(GLshort)*2);
  glRectsv(v1_s, v2_s);

void
glTexCoord1dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*1);
  glTexCoord1dv(v_s);

void
glTexCoord1fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*1);
  glTexCoord1fv(v_s);

void
glTexCoord1iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*1);
  glTexCoord1iv(v_s);

void
glTexCoord1sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*1);
  glTexCoord1sv(v_s);

void
glTexCoord2dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*2);
  glTexCoord2dv(v_s);

void
glTexCoord2fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*2);
  glTexCoord2fv(v_s);

void
glTexCoord2iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*2);
  glTexCoord2iv(v_s);

void
glTexCoord2sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*2);
  glTexCoord2sv(v_s);

void
glTexCoord3dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glTexCoord3dv(v_s);

void
glTexCoord3fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glTexCoord3fv(v_s);

void
glTexCoord3iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glTexCoord3iv(v_s);

void
glTexCoord3sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glTexCoord3sv(v_s);

void
glTexCoord4dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glTexCoord4dv(v_s);

void
glTexCoord4fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glTexCoord4fv(v_s);

void
glTexCoord4iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glTexCoord4iv(v_s);

void
glTexCoord4sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glTexCoord4sv(v_s);

void
glTexEnvfv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureEnvParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureEnvParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glTexEnvfv(target, pname, params_s);

void
glTexEnviv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureEnvParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureEnvParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glTexEnviv(target, pname, params_s);

void
glTexGendv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  const GLdouble *params_s = EL(params, sizeof(GLdouble)*pname_count);
  glTexGendv(coord, pname, params_s);

void
glTexGenfv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glTexGenfv(coord, pname, params_s);

void
glTexGeniv_s(coord, pname, params)
  GLenum coord
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureGenParameter_count(pname);
  if (pname_count < 0) croak("Unknown TextureGenParameter parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glTexGeniv(coord, pname, params_s);

void
glTexParameterfv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureParameterName_count(pname);
  if (pname_count < 0) croak("Unknown TextureParameterName parameter");
  const GLfloat *params_s = EL(params, sizeof(GLfloat)*pname_count);
  glTexParameterfv(target, pname, params_s);

void
glTexParameteriv_s(target, pname, params)
  GLenum target
  GLenum pname
  SV *params
CODE:
  int pname_count = gl_TextureParameterName_count(pname);
  if (pname_count < 0) croak("Unknown TextureParameterName parameter");
  const GLint *params_s = EL(params, sizeof(GLint)*pname_count);
  glTexParameteriv(target, pname, params_s);

#ifdef GL_ARB_shader_objects

void
glUniform1fvARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform1fvARB,"glUniform1fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*1);
  glUniform1fvARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform1ivARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform1ivARB,"glUniform1ivARB");
CODE:
  const GLint* value_s = EL(value, sizeof(GLint)*count*1);
  glUniform1ivARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform2fvARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform2fvARB,"glUniform2fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*2);
  glUniform2fvARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform2ivARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform2ivARB,"glUniform2ivARB");
CODE:
  const GLint* value_s = EL(value, sizeof(GLint)*count*2);
  glUniform2ivARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform3fvARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform3fvARB,"glUniform3fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*3);
  glUniform3fvARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform3ivARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform3ivARB,"glUniform3ivARB");
CODE:
  const GLint* value_s = EL(value, sizeof(GLint)*count*3);
  glUniform3ivARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform4fvARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform4fvARB,"glUniform4fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*4);
  glUniform4fvARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniform4ivARB_s(location, count, value)
  GLint location
  GLsizei count
  SV *value
INIT:
  loadProc(glUniform4ivARB,"glUniform4ivARB");
CODE:
  const GLint* value_s = EL(value, sizeof(GLint)*count*4);
  glUniform4ivARB(location, count, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniformMatrix2fvARB_s(location, count, transpose, value)
  GLint location
  GLsizei count
  GLboolean transpose
  SV *value
INIT:
  loadProc(glUniformMatrix2fvARB,"glUniformMatrix2fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*4);
  glUniformMatrix2fvARB(location, count, transpose, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniformMatrix3fvARB_s(location, count, transpose, value)
  GLint location
  GLsizei count
  GLboolean transpose
  SV *value
INIT:
  loadProc(glUniformMatrix3fvARB,"glUniformMatrix3fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*9);
  glUniformMatrix3fvARB(location, count, transpose, value_s);

#endif

#ifdef GL_ARB_shader_objects

void
glUniformMatrix4fvARB_s(location, count, transpose, value)
  GLint location
  GLsizei count
  GLboolean transpose
  SV *value
INIT:
  loadProc(glUniformMatrix4fvARB,"glUniformMatrix4fvARB");
CODE:
  const GLfloat* value_s = EL(value, sizeof(GLfloat)*count*16);
  glUniformMatrix4fvARB(location, count, transpose, value_s);

#endif

void
glVertex2dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*2);
  glVertex2dv(v_s);

void
glVertex2fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*2);
  glVertex2fv(v_s);

void
glVertex2iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*2);
  glVertex2iv(v_s);

void
glVertex2sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*2);
  glVertex2sv(v_s);

void
glVertex3dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*3);
  glVertex3dv(v_s);

void
glVertex3fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*3);
  glVertex3fv(v_s);

void
glVertex3iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*3);
  glVertex3iv(v_s);

void
glVertex3sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*3);
  glVertex3sv(v_s);

void
glVertex4dv_s(v)
  SV *v
CODE:
  const GLdouble *v_s = EL(v, sizeof(GLdouble)*4);
  glVertex4dv(v_s);

void
glVertex4fv_s(v)
  SV *v
CODE:
  const GLfloat *v_s = EL(v, sizeof(GLfloat)*4);
  glVertex4fv(v_s);

void
glVertex4iv_s(v)
  SV *v
CODE:
  const GLint *v_s = EL(v, sizeof(GLint)*4);
  glVertex4iv(v_s);

void
glVertex4sv_s(v)
  SV *v
CODE:
  const GLshort *v_s = EL(v, sizeof(GLshort)*4);
  glVertex4sv(v_s);

#ifdef GL_ARB_vertex_program

void
glVertexAttrib1dvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib1dvARB,"glVertexAttrib1dvARB");
CODE:
  const GLdouble* v_s = EL(v, sizeof(GLdouble)*1);
  glVertexAttrib1dvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib1fvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib1fvARB,"glVertexAttrib1fvARB");
CODE:
  const GLfloat* v_s = EL(v, sizeof(GLfloat)*1);
  glVertexAttrib1fvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib1svARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib1svARB,"glVertexAttrib1svARB");
CODE:
  const GLshort* v_s = EL(v, sizeof(GLshort)*1);
  glVertexAttrib1svARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib2dvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib2dvARB,"glVertexAttrib2dvARB");
CODE:
  const GLdouble* v_s = EL(v, sizeof(GLdouble)*2);
  glVertexAttrib2dvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib2fvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib2fvARB,"glVertexAttrib2fvARB");
CODE:
  const GLfloat* v_s = EL(v, sizeof(GLfloat)*2);
  glVertexAttrib2fvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib2svARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib2svARB,"glVertexAttrib2svARB");
CODE:
  const GLshort* v_s = EL(v, sizeof(GLshort)*2);
  glVertexAttrib2svARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib3dvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib3dvARB,"glVertexAttrib3dvARB");
CODE:
  const GLdouble* v_s = EL(v, sizeof(GLdouble)*3);
  glVertexAttrib3dvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib3fvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib3fvARB,"glVertexAttrib3fvARB");
CODE:
  const GLfloat* v_s = EL(v, sizeof(GLfloat)*3);
  glVertexAttrib3fvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib3svARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib3svARB,"glVertexAttrib3svARB");
CODE:
  const GLshort* v_s = EL(v, sizeof(GLshort)*3);
  glVertexAttrib3svARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NbvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NbvARB,"glVertexAttrib4NbvARB");
CODE:
  const GLbyte* v_s = EL(v, sizeof(GLbyte)*4);
  glVertexAttrib4NbvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NivARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NivARB,"glVertexAttrib4NivARB");
CODE:
  const GLint* v_s = EL(v, sizeof(GLint)*4);
  glVertexAttrib4NivARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NsvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NsvARB,"glVertexAttrib4NsvARB");
CODE:
  const GLshort* v_s = EL(v, sizeof(GLshort)*4);
  glVertexAttrib4NsvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NubvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NubvARB,"glVertexAttrib4NubvARB");
CODE:
  const GLubyte* v_s = EL(v, sizeof(GLubyte)*4);
  glVertexAttrib4NubvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NuivARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NuivARB,"glVertexAttrib4NuivARB");
CODE:
  const GLuint* v_s = EL(v, sizeof(GLuint)*4);
  glVertexAttrib4NuivARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4NusvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4NusvARB,"glVertexAttrib4NusvARB");
CODE:
  const GLushort* v_s = EL(v, sizeof(GLushort)*4);
  glVertexAttrib4NusvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4bvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4bvARB,"glVertexAttrib4bvARB");
CODE:
  const GLbyte* v_s = EL(v, sizeof(GLbyte)*4);
  glVertexAttrib4bvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4dvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4dvARB,"glVertexAttrib4dvARB");
CODE:
  const GLdouble* v_s = EL(v, sizeof(GLdouble)*4);
  glVertexAttrib4dvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4fvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4fvARB,"glVertexAttrib4fvARB");
CODE:
  const GLfloat* v_s = EL(v, sizeof(GLfloat)*4);
  glVertexAttrib4fvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4ivARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4ivARB,"glVertexAttrib4ivARB");
CODE:
  const GLint* v_s = EL(v, sizeof(GLint)*4);
  glVertexAttrib4ivARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4svARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4svARB,"glVertexAttrib4svARB");
CODE:
  const GLshort* v_s = EL(v, sizeof(GLshort)*4);
  glVertexAttrib4svARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4ubvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4ubvARB,"glVertexAttrib4ubvARB");
CODE:
  const GLubyte* v_s = EL(v, sizeof(GLubyte)*4);
  glVertexAttrib4ubvARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4uivARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4uivARB,"glVertexAttrib4uivARB");
CODE:
  const GLuint* v_s = EL(v, sizeof(GLuint)*4);
  glVertexAttrib4uivARB(index, v_s);

#endif

#ifdef GL_ARB_vertex_program

void
glVertexAttrib4usvARB_s(index, v)
  GLuint index
  SV *v
INIT:
  loadProc(glVertexAttrib4usvARB,"glVertexAttrib4usvARB");
CODE:
  const GLushort* v_s = EL(v, sizeof(GLushort)*4);
  glVertexAttrib4usvARB(index, v_s);

#endif

