summaryrefslogtreecommitdiff
path: root/main.cpp
blob: 643b3b428d927676a4b32297e138cc56f1e070d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#include "video.h"
#include "scene.h"

#include "gl.h"

int main(int argc, char **argv) {
	video::width = 1280;
	video::height = 720;
	video::init();

#ifdef WIN32
	win32_gl_init();
#ifdef CEGUI_STATIC
#warning "cegui static"
#endif
#endif

	Scene scene;

	SDL_ShowCursor(SDL_DISABLE);

	SDL_WarpMouse(video::width/2, video::height/2);
	scene.last_time = SDL_GetTicks();
	scene.update();
	while(scene.running) {
		scene.events();
		scene.render();

		SDL_Delay(1);
	}

	video::free();

	return 0;
}