annotate pytouhou/ui/renderer.pxd @ 412:5fe6cd6ceb48

Refactor the maths functions out of Renderer.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Wed, 12 Jun 2013 18:30:08 +0200
parents 1c773544eaeb
children d8630c086926
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
222
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
1 cdef struct Vertex:
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
2 int x, y, z
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
3 float u, v
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
4 unsigned char r, g, b, a
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
5
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
6
399
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
7 cdef struct VertexFloat:
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
8 float x, y, z
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
9 float u, v
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
10 unsigned char r, g, b, a
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
11
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
12
222
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
13 cdef class Renderer:
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
14 cdef public texture_manager
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
15 cdef Vertex *vertex_buffer
399
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
16 cdef object texture_key
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
17 cdef unsigned short blendfunc, nb_vertices
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
18 cdef VertexFloat *background_vertex_buffer
222
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
19
5cac48b328ad Refactor rendering code a bit.
Thibaut Girka <thib@sitedethib.com>
parents:
diff changeset
20 cpdef render_elements(self, elements)
399
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
21 cpdef render_background(self)
1c773544eaeb Make the background use a single vbo and offsets, just like the 2D code.
Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
parents: 398
diff changeset
22 cpdef prerender_background(self, background)