annotate pytouhou/lib/opengl.pxd @ 498:c9c2fb873dbd

Actually consume a bomb when using it, make the player invulnerable for a certain time, and implement deathbomb.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Mon, 14 Oct 2013 12:45:21 +0200
parents 2276229282fd
children 75ae628522c9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
423
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
1 # -*- encoding: utf-8 -*-
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
2 ##
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
3 ## Copyright (C) 2013 Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
4 ##
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
5 ## This program is free software; you can redistribute it and/or modify
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
6 ## it under the terms of the GNU General Public License as published
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
7 ## by the Free Software Foundation; version 3 only.
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
8 ##
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
9 ## This program is distributed in the hope that it will be useful,
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
10 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
11 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
12 ## GNU General Public License for more details.
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
13 ##
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
14
450
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
15
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
16 IF USE_GLEW:
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
17 cdef extern from 'GL/glew.h' nogil:
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
18 GLenum glewInit()
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
19
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
20
2a352118c55a Add back Windows support, using GLEW for OpenGL.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 426
diff changeset
21 cdef extern from 'GL/gl.h' nogil:
423
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
22 ctypedef unsigned int GLuint
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
23 ctypedef int GLint
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
24 ctypedef float GLfloat
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
25 ctypedef float GLclampf
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
26 ctypedef char GLboolean
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
27 ctypedef char GLchar
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
28 ctypedef unsigned int GLsizei
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
29 ctypedef unsigned int GLsizeiptr
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
30 ctypedef unsigned int GLbitfield
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
31 ctypedef void GLvoid
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
32
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
33 ctypedef enum GLenum:
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
34 GL_ARRAY_BUFFER
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
35 GL_STATIC_DRAW
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
36 GL_DYNAMIC_DRAW
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
37 GL_UNSIGNED_BYTE
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
38 GL_UNSIGNED_SHORT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
39 GL_INT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
40 GL_FLOAT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
41 GL_SRC_ALPHA
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
42 GL_ONE_MINUS_SRC_ALPHA
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
43 GL_ONE
462
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
44 GL_ZERO
423
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
45 GL_TEXTURE_2D
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
46 GL_TRIANGLES
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
47 GL_DEPTH_TEST
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
48 GL_QUADS
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
49
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
50 GL_TEXTURE_MIN_FILTER
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
51 GL_TEXTURE_MAG_FILTER
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
52 GL_LINEAR
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
53 GL_BGRA
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
54 GL_RGBA
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
55 GL_RGB
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
56 GL_LUMINANCE
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
57 GL_UNSIGNED_SHORT_5_6_5
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
58 GL_UNSIGNED_SHORT_4_4_4_4_REV
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
59
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
60 GL_COLOR_BUFFER_BIT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
61 GL_SCISSOR_TEST
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
62 GL_MODELVIEW
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
63 GL_FOG
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
64
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
65 GL_DEPTH_BUFFER_BIT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
66 GL_PROJECTION
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
67 GL_FOG_MODE
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
68 GL_FOG_START
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
69 GL_FOG_END
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
70 GL_FOG_COLOR
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
71
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
72 GL_BLEND
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
73 GL_PERSPECTIVE_CORRECTION_HINT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
74 GL_FOG_HINT
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
75 GL_NICEST
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
76 GL_COLOR_ARRAY
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
77 GL_VERTEX_ARRAY
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
78 GL_TEXTURE_COORD_ARRAY
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
79
424
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
80 GL_VERTEX_SHADER
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
81 GL_FRAGMENT_SHADER
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
82 GL_INFO_LOG_LENGTH
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
83 GL_COMPILE_STATUS
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
84 GL_LINK_STATUS
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
85
462
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
86 GL_FRAMEBUFFER
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
87 GL_COLOR_ATTACHMENT0
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
88 GL_RENDERBUFFER
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
89 GL_DEPTH_COMPONENT
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
90 GL_DEPTH_ATTACHMENT
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
91 GL_FRAMEBUFFER_COMPLETE
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
92
423
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
93 void glVertexPointer(GLint size, GLenum type_, GLsizei stride, GLvoid *pointer)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
94 void glTexCoordPointer(GLint size, GLenum type_, GLsizei stride, GLvoid *pointer)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
95 void glColorPointer(GLint size, GLenum type_, GLsizei stride, GLvoid *pointer)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
96
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
97 void glBlendFunc(GLenum sfactor, GLenum dfactor)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
98 void glDrawArrays(GLenum mode, GLint first, GLsizei count)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
99 void glDrawElements(GLenum mode, GLsizei count, GLenum type_, const GLvoid *indices)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
100 void glEnable(GLenum cap)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
101 void glDisable(GLenum cap)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
102
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
103 void glGenTextures(GLsizei n, GLuint *textures)
426
5d7bb2fd74f7 Never keep texture on the host when it has been uploaded, and prevent them from being decoded again.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 424
diff changeset
104 void glDeleteTextures(GLsizei n, const GLuint *textures)
423
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
105 void glBindTexture(GLenum target, GLuint texture)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
106 void glTexParameteri(GLenum target, GLenum pname, GLint param)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
107 void glTexImage2D(GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format_, GLenum type_, const GLvoid *data)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
108
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
109 void glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) #XXX
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
110 void glClear(GLbitfield mask)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
111 void glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
112 void glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
113 void glMatrixMode(GLenum mode)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
114 void glLoadIdentity()
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
115 void glLoadMatrixf(const GLfloat * m)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
116
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
117 void glFogi(GLenum pname, GLint param)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
118 void glFogf(GLenum pname, GLfloat param)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
119 void glFogfv(GLenum pname, const GLfloat * params)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
120
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
121 void glHint(GLenum target, GLenum mode)
d8630c086926 Replace Pyglet with our own Cython OpenGL wrapper.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents:
diff changeset
122 void glEnableClientState(GLenum cap)
424
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
123
491
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
124
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
125 cdef extern from 'GL/glext.h' nogil:
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
126 void glVertexAttribPointer(GLuint index, GLint size, GLenum type_, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
127 void glEnableVertexAttribArray(GLuint index)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
128
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
129 void glGenBuffers(GLsizei n, GLuint * buffers)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
130 void glDeleteBuffers(GLsizei n, const GLuint * buffers)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
131 void glBindBuffer(GLenum target, GLuint buffer_)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
132 void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
2276229282fd Fix gcc’s warnings with -Wall -Wextra.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 462
diff changeset
133
424
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
134 GLuint glCreateProgram()
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
135 GLuint glCreateShader(GLenum shaderType)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
136 void glLinkProgram(GLuint program)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
137 void glUseProgram(GLuint program)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
138 void glGetProgramiv(GLuint program, GLenum pname, GLint *params)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
139 void glGetProgramInfoLog(GLuint program, GLsizei maxLength, GLsizei *length, GLchar *infoLog)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
140
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
141 void glShaderSource(GLuint shader, GLsizei count, const GLchar **string, const GLint *length)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
142 void glCompileShader(GLuint shader)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
143 void glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
144 void glGetShaderInfoLog(GLuint shader, GLsizei maxLength, GLsizei *length, GLchar *infoLog)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
145 void glAttachShader(GLuint program, GLuint shader)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
146
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
147 GLint glGetUniformLocation(GLuint program, const GLchar *name)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
148 void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
149 void glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
150 void glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
f4d76d3d6f2a Make the Shader class use cython too.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 423
diff changeset
151 void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
462
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
152
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
153 void glGenFramebuffers(GLsizei n, GLuint *ids)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
154 void glBindFramebuffer(GLenum target, GLuint framebuffer)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
155 void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
156 void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
157 void glBindRenderbuffer(GLenum target, GLuint renderbuffer)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
158 void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
159 void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
a71b912b45b7 Render to framebuffers first, and reposition some interface elements in the game area.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 450
diff changeset
160 GLenum glCheckFramebufferStatus(GLenum target)