implemented a laser pointer
[vrfileman] / src / app.h
1 #ifndef APP_H_
2 #define APP_H_
3
4 #include "gmath/gmath.h"
5 #include "opt.h"
6
7 extern int win_width, win_height;
8 extern float win_aspect;
9 extern long time_msec;
10 extern double time_sec;
11
12 extern float cam_height;
13 extern Mat4 view_matrix;
14
15
16 bool app_init(int argc, char **argv);
17 void app_cleanup();
18
19 void app_draw();
20 void app_reshape(int x, int y);
21 void app_keyboard(int key, bool pressed);
22 void app_mouse_button(int bn, bool pressed, int x, int y);
23 void app_mouse_motion(int x, int y);
24 void app_mouse_delta(int dx, int dy);
25
26 // the following functions are implemented by the window system backend
27 void app_resize(int x, int y);
28 void app_fullscreen(bool fs);
29 void app_toggle_fullscreen();
30 bool app_is_fullscreen();
31 void app_grab_mouse(bool grab);
32 void app_toggle_grab_mouse();
33 bool app_is_mouse_grabbed();
34 void app_quit();
35 void app_redraw();
36 void app_swap_buffers();
37 long app_get_msec();
38
39 #endif  // APP_H_