summaryrefslogtreecommitdiff
path: root/src/egl.h
blob: a3f17a2eb279084dc06f179f18aca4bae968ba2f (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
#ifndef EGL_H
#define EGL_H

#include <wayland-egl.h>
#include <epoxy/egl.h>

struct egl {
	EGLNativeWindowType window;
	EGLDisplay display;
	EGLContext context;
	EGLSurface surface;
};

void egl_create_window(
		struct egl *egl,
		struct wl_surface *wl_surface,
		uint32_t width,
		uint32_t height);
void egl_create_context(struct egl *egl, struct wl_display *wl_display);
void egl_destroy(struct egl *egl);
void egl_log_error(const char *msg);
void egl_make_current(struct egl *egl);
void egl_swap_buffers(struct egl *egl);

#endif /* EGL_H */