From f05afa10b33729113e23de9f8606af5537824dbb Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Sat, 2 Feb 2013 21:38:35 -0500 Subject: [PATCH] correct aspect ratio --- sdl_opengl_bare.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdl_opengl_bare.d b/sdl_opengl_bare.d index 345cbdd..f052310 100644 --- a/sdl_opengl_bare.d +++ b/sdl_opengl_bare.d @@ -13,7 +13,7 @@ void init() glViewport(0, 0, WIDTH, HEIGHT); glMatrixMode(GL_PROJECTION); glLoadIdentity(); - gluPerspective(60.0, cast(GLfloat)WIDTH/cast(GLfloat)WIDTH, 1.0, 30.0); + gluPerspective(60.0, cast(GLfloat)WIDTH/cast(GLfloat)HEIGHT, 1.0, 30.0); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); glTranslatef(0.0, 0.0, -10.0);