… | |
… | |
6 | #include <cstdio> // ugly |
6 | #include <cstdio> // ugly |
7 | #include <cmath> |
7 | #include <cmath> |
8 | |
8 | |
9 | #include <sys/time.h> |
9 | #include <sys/time.h> |
10 | #include <time.h> |
10 | #include <time.h> |
|
|
11 | |
11 | #include <GL/gl.h> |
12 | #include <GL/gl.h> |
|
|
13 | #include <GL/glut.h> |
12 | |
14 | |
13 | #include "util.h" |
15 | #include "util.h" |
14 | #include "entity.h" |
16 | #include "entity.h" |
15 | |
17 | |
16 | #define DEG2RAD (M_PI / 180.) |
18 | #define DEG2RAD (M_PI / 180.) |
… | |
… | |
272 | SDL_FreeSurface (image); /* No longer needed */ |
274 | SDL_FreeSurface (image); /* No longer needed */ |
273 | |
275 | |
274 | return texture; |
276 | return texture; |
275 | } |
277 | } |
276 | |
278 | |
|
|
279 | void render_text (GLint x, GLint y, const char *str) |
|
|
280 | { |
|
|
281 | glRasterPos2i (x, y); |
|
|
282 | |
|
|
283 | while (!*str) |
|
|
284 | glutBitmapCharacter (GLUT_BITMAP_HELVETICA_18, *str++); |
|
|
285 | } |
|
|
286 | |
277 | //skedjuhlar main_scheduler; |
287 | //skedjuhlar main_scheduler; |
278 | |
288 | |