summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/main.c b/src/main.c
index eb655b7..c168e6f 100644
--- a/src/main.c
+++ b/src/main.c
@@ -60,9 +60,9 @@ int killGame(Game* game)
return 0;
}
-void setupProjection(Game* game)
+void setupProjection(float fov, Game* game)
{
- glm_perspective(90.0f, ((float)game->window_width)/((float)game->window_height), 0.1f, 40.0f, game->projection);
+ glm_perspective(fov, ((float)game->window_width)/((float)game->window_height), 0.1f, 40.0f, game->projection);
glUniformMatrix4fv(game->projection_loc, 1, GL_FALSE, (float*)game->projection);
}
@@ -118,14 +118,12 @@ int main()
game.transform_loc = glGetUniformLocation(shader_program, "model");
game.projection_loc = glGetUniformLocation(shader_program, "projection");
- SDL_Time time;
-
// Enable/disable wireframe rendering:
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
glUseProgram(shader_program);
- setupProjection(&game);
+ setupProjection(90.0f, &game);
bindViewModel(&pengerModel);
while (game.running) {