Merge branch '7.8'
[mesa.git] / progs / egl / eglut / eglut.h
1 #ifndef EGLUT_H
2 #define EGLUT_H
3
4 /* used by eglutInitAPIMask */
5 enum {
6 EGLUT_OPENGL_BIT = 0x1,
7 EGLUT_OPENGL_ES1_BIT = 0x2,
8 EGLUT_OPENGL_ES2_BIT = 0x4,
9 EGLUT_OPENVG_BIT = 0x8
10 };
11
12 /* used by EGLUTspecialCB */
13 enum {
14 /* function keys */
15 EGLUT_KEY_F1,
16 EGLUT_KEY_F2,
17 EGLUT_KEY_F3,
18 EGLUT_KEY_F4,
19 EGLUT_KEY_F5,
20 EGLUT_KEY_F6,
21 EGLUT_KEY_F7,
22 EGLUT_KEY_F8,
23 EGLUT_KEY_F9,
24 EGLUT_KEY_F10,
25 EGLUT_KEY_F11,
26 EGLUT_KEY_F12,
27
28 /* directional keys */
29 EGLUT_KEY_LEFT,
30 EGLUT_KEY_UP,
31 EGLUT_KEY_RIGHT,
32 EGLUT_KEY_DOWN,
33 };
34
35 /* used by eglutGet */
36 enum {
37 EGLUT_ELAPSED_TIME
38 };
39
40 typedef void (*EGLUTidleCB)(void);
41 typedef void (*EGLUTreshapeCB)(int, int);
42 typedef void (*EGLUTdisplayCB)(void);
43 typedef void (*EGLUTkeyboardCB)(unsigned char);
44 typedef void (*EGLUTspecialCB)(int);
45
46 void eglutInitAPIMask(int mask);
47 void eglutInitWindowSize(int width, int height);
48 void eglutInit(int argc, char **argv);
49
50 int eglutGet(int state);
51
52 void eglutIdleFunc(EGLUTidleCB func);
53 void eglutPostRedisplay(void);
54
55 void eglutMainLoop(void);
56
57 int eglutCreateWindow(const char *title);
58
59 int eglutGetWindowWidth(void);
60 int eglutGetWindowHeight(void);
61
62 void eglutDisplayFunc(EGLUTdisplayCB func);
63 void eglutReshapeFunc(EGLUTreshapeCB func);
64 void eglutKeyboardFunc(EGLUTkeyboardCB func);
65 void eglutSpecialFunc(EGLUTspecialCB func);
66
67 #endif /* EGLUT_H */