diff options
Diffstat (limited to '')
-rw-r--r-- | libraries/evas/src/modules/engines/wayland_egl/evas_engine.h | 82 |
1 files changed, 82 insertions, 0 deletions
diff --git a/libraries/evas/src/modules/engines/wayland_egl/evas_engine.h b/libraries/evas/src/modules/engines/wayland_egl/evas_engine.h new file mode 100644 index 0000000..204d793 --- /dev/null +++ b/libraries/evas/src/modules/engines/wayland_egl/evas_engine.h | |||
@@ -0,0 +1,82 @@ | |||
1 | #ifndef EVAS_ENGINE_H | ||
2 | #define EVAS_ENGINE_H | ||
3 | |||
4 | #include "config.h" | ||
5 | #include "evas_common.h" | ||
6 | #include "evas_private.h" | ||
7 | #include "evas_gl_common.h" | ||
8 | #include "Evas.h" | ||
9 | #include "Evas_Engine_Wayland_Egl.h" | ||
10 | |||
11 | #define GL_GLEXT_PROTOTYPES | ||
12 | |||
13 | #include <EGL/egl.h> | ||
14 | #include <GLES2/gl2.h> | ||
15 | #include <GLES2/gl2ext.h> | ||
16 | #include <wayland-egl.h> | ||
17 | |||
18 | extern int _evas_engine_wl_egl_log_dom; | ||
19 | #ifdef ERR | ||
20 | # undef ERR | ||
21 | #endif | ||
22 | #define ERR(...) EINA_LOG_DOM_ERR(_evas_engine_wl_egl_log_dom, __VA_ARGS__) | ||
23 | |||
24 | #ifdef DBG | ||
25 | # undef DBG | ||
26 | #endif | ||
27 | #define DBG(...) EINA_LOG_DOM_DBG(_evas_engine_wl_egl_log_dom, __VA_ARGS__) | ||
28 | |||
29 | #ifdef INF | ||
30 | # undef INF | ||
31 | #endif | ||
32 | #define INF(...) EINA_LOG_DOM_INFO(_evas_engine_wl_egl_log_dom, __VA_ARGS__) | ||
33 | |||
34 | #ifdef WRN | ||
35 | # undef WRN | ||
36 | #endif | ||
37 | #define WRN(...) EINA_LOG_DOM_WARN(_evas_engine_wl_egl_log_dom, __VA_ARGS__) | ||
38 | |||
39 | #ifdef CRIT | ||
40 | # undef CRIT | ||
41 | #endif | ||
42 | #define CRIT(...) EINA_LOG_DOM_CRIT(_evas_engine_wl_egl_log_dom, __VA_ARGS__) | ||
43 | |||
44 | typedef struct _Evas_GL_Wl_Window Evas_GL_Wl_Window; | ||
45 | |||
46 | struct _Evas_GL_Wl_Window | ||
47 | { | ||
48 | struct wl_display *disp; | ||
49 | struct wl_egl_window *win; | ||
50 | struct wl_surface *surface; | ||
51 | int w, h; | ||
52 | int screen; | ||
53 | // XVisualInfo *visualinfo; | ||
54 | // Visual *visual; | ||
55 | // Colormap colormap; | ||
56 | int depth; | ||
57 | int alpha; | ||
58 | int rot; | ||
59 | Evas_Engine_GL_Context *gl_context; | ||
60 | struct { | ||
61 | int redraw : 1; | ||
62 | int drew : 1; | ||
63 | int x1, y1, x2, y2; | ||
64 | } draw; | ||
65 | EGLContext egl_context[1]; | ||
66 | EGLSurface egl_surface[1]; | ||
67 | EGLConfig egl_config; | ||
68 | EGLDisplay egl_disp; | ||
69 | int surf : 1; | ||
70 | }; | ||
71 | |||
72 | Evas_GL_Wl_Window *eng_window_new(struct wl_display *disp, struct wl_surface *surface, int screen, | ||
73 | int depth, int w, int h, int indirect, | ||
74 | int alpha, int rot); | ||
75 | void eng_window_free(Evas_GL_Wl_Window *gw); | ||
76 | void eng_window_use(Evas_GL_Wl_Window *gw); | ||
77 | void eng_window_unsurf(Evas_GL_Wl_Window *gw); | ||
78 | void eng_window_resurf(Evas_GL_Wl_Window *gw); | ||
79 | |||
80 | int eng_best_depth_get(Evas_Engine_Info_Wayland_Egl *einfo); | ||
81 | |||
82 | #endif | ||