Mercurial > touhou
comparison pytouhou/ui/renderer.pxd @ 464:36bc577b2392
Make the window resizable, and scale its content correctly.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Wed, 11 Sep 2013 15:55:19 +0200 |
parents | a71b912b45b7 |
children | feecdb4a8928 |
comparison
equal
deleted
inserted
replaced
463:11708a1d0a1a | 464:36bc577b2392 |
---|---|
1 from cpython cimport PyObject | 1 from cpython cimport PyObject |
2 from .window cimport Window | |
2 from pytouhou.lib.opengl cimport GLuint | 3 from pytouhou.lib.opengl cimport GLuint |
3 | 4 |
4 cdef struct Vertex: | 5 cdef struct Vertex: |
5 int x, y, z | 6 int x, y, z |
6 float u, v | 7 float u, v |
23 cdef unsigned short last_indices[2 * MAX_TEXTURES] | 24 cdef unsigned short last_indices[2 * MAX_TEXTURES] |
24 cdef PyObject *elements[640*3] | 25 cdef PyObject *elements[640*3] |
25 | 26 |
26 cpdef render_elements(self, elements) | 27 cpdef render_elements(self, elements) |
27 cpdef render_quads(self, rects, colors, texture) | 28 cpdef render_quads(self, rects, colors, texture) |
28 cpdef render_framebuffer(self, Framebuffer fb) | 29 cpdef render_framebuffer(self, Framebuffer fb, Window window) |
29 | 30 |
30 | 31 |
31 cdef class Framebuffer: | 32 cdef class Framebuffer: |
32 cdef GLuint fbo, texture, rbo | 33 cdef GLuint fbo, texture, rbo |
33 cdef int x, y, width, height | 34 cdef int x, y, width, height |