diff options
Diffstat (limited to 'sdl/pyramid.c')
-rw-r--r-- | sdl/pyramid.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sdl/pyramid.c b/sdl/pyramid.c index fc95fd6..566c976 100644 --- a/sdl/pyramid.c +++ b/sdl/pyramid.c @@ -21,6 +21,7 @@ #include <GL/glew.h> #include <GL/freeglut.h> #include <sys/time.h> +#include "gldraw.h" #include "glframe.h" #include "gltools.h" #include "math3d.h" @@ -207,14 +208,14 @@ static void platform_init(void) glNewList(p.ground_list, GL_COMPILE); //glBindTexture(GL_TEXTURE_2D, p.textures[1]); glColor3ub(255, 0, 255); - gltDrawGround(); + glDrawGround(); glEndList(); /* a triangle with a texture */ glNewList(p.triangle_list, GL_COMPILE); glBindTexture(GL_TEXTURE_2D, p.textures[0]); glColor3f(1.0f, 1.0f, 1.0f); - gltDrawTriangle(); + glDrawTriangle(); glEndList(); } @@ -248,7 +249,7 @@ static void render(void) /* draw a snowman */ glTranslatef(0.0f, 0.0f, -7.0f); - gltDrawSnowman(); + glDrawSnowman(); /* restore the matrix state */ glPopMatrix(); @@ -263,9 +264,9 @@ int main(int argc, char **argv) setup_glew(); setup_opengl(); platform_init(); + gltErrorCheck(); unsigned int startclock; - while (program_running) { startclock = SDL_GetTicks(); @@ -274,7 +275,6 @@ int main(int argc, char **argv) render(); fps_control(startclock); - /* need some sort of a timer to trigger this */ /* gl_frame_normalize(&p.camera); */ } |