summaryrefslogtreecommitdiff
path: root/src/graphics.h
blob: 1ab4651d604105a6e0f790def5ee78554ef4899e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#pragma once

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

enum graphics_error_e {
  GRAPHICS_ERROR_NONE = 0,
  GRAPHICS_ERROR_DISPLAY,
};

struct graphics_s {
  EGLDisplay display;
  EGLContext context;
  EGLConfig config;
};

enum graphics_error_e wayc_graphics_init(struct graphics_s* graphics,
                                         struct wlstate_s* state);
void wayc_graphics_deinit(struct graphics_s* graphics);