Merge remote branch 'origin/master' into pipe-video
[mesa.git] / src / egl / wayland / wayland-egl / wayland-egl-priv.h
1 #ifndef _WAYLAND_EGL_PRIV_H
2 #define _WAYLAND_EGL_PRIV_H
3
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7
8 /* GCC visibility */
9 #if defined(__GNUC__) && __GNUC__ >= 4
10 #define WL_EGL_EXPORT __attribute__ ((visibility("default")))
11 #else
12 #define WL_EGL_EXPORT
13 #endif
14
15 #include <stdbool.h>
16 #include <wayland-client.h>
17
18 struct wl_egl_display {
19 struct wl_display *display;
20
21 struct wl_drm *drm;
22 int fd;
23 char *device_name;
24 bool authenticated;
25
26 void (*glFlush)(void);
27 };
28
29 struct wl_egl_window {
30 struct wl_surface *surface;
31 struct wl_visual *visual;
32
33 int width;
34 int height;
35 int dx;
36 int dy;
37
38 int attached_width;
39 int attached_height;
40 };
41
42 struct wl_egl_pixmap {
43 struct wl_egl_display *display;
44 struct wl_visual *visual;
45 struct wl_buffer *buffer;
46
47 int width;
48 int height;
49
50 void (*destroy) (struct wl_egl_pixmap *egl_pixmap);
51
52 void *driver_private;
53 };
54
55 #ifdef __cplusplus
56 }
57 #endif
58
59 #endif