vrheights

diff src/game.cc @ 0:ccbd444939a1

initial commit
author John Tsiombikas <nuclear@member.fsf.org>
date Mon, 22 Sep 2014 18:36:24 +0300
parents
children d06e4e24f922
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/game.cc	Mon Sep 22 18:36:24 2014 +0300
     1.3 @@ -0,0 +1,29 @@
     1.4 +#include <stdio.h>
     1.5 +#include "opengl.h"
     1.6 +#include "game.h"
     1.7 +#include "goatvr.h"
     1.8 +
     1.9 +bool game_init()
    1.10 +{
    1.11 +	init_opengl();
    1.12 +
    1.13 +	if(vr_init() == -1) {
    1.14 +		return false;
    1.15 +	}
    1.16 +
    1.17 +	glEnable(GL_DEPTH_TEST);
    1.18 +	glEnable(GL_CULL_FACE);
    1.19 +}
    1.20 +
    1.21 +void game_cleanup()
    1.22 +{
    1.23 +	vr_shutdown();
    1.24 +}
    1.25 +
    1.26 +void game_update(long tm);
    1.27 +void game_display();
    1.28 +void game_reshape(int x, int y);
    1.29 +void game_keyboard(int key, bool pressed);
    1.30 +void game_mouse_button(int bn, bool state, int x, int y);
    1.31 +void game_mouse_motion(int x, int y);
    1.32 +