#ifndef MR4TH_OSW_OGL_EGL_H
#define MR4TH_OSW_OGL_EGL_H

////////////////////////////////
// EGL Includes

#if OSW_IMPL_X11
// TODO(allen): 
#elif OSW_IMPL_WAYLAND
#include <wayland-egl.h>
#endif

#include <EGL/egl.h>
#include <EGL/eglext.h>

////////////////////////////////
// EGL Types

typedef struct OSW_EGL_Ctx{
  EGLDisplay egl_display;
  EGLContext egl_context;
} OSW_EGL_Ctx;

typedef struct OSW_EGL_Window{
  B32        activated;
  EGLSurface main_egl_surface;
  
#if OSW_IMPL_X11
  // TODO(allen): 
#elif OSW_IMPL_WAYLAND
  struct wl_egl_window  *main_wl_egl_window;
#endif
} OSW_EGL_Window;

////////////////////////////////
// EGL Functions

static B32  osw__egl_open(void);
static void osw__egl_close(void);
static void osw__egl_begin(OSW_Window *window);
static void osw__egl_end(OSW_Window *window);

#endif //MR4TH_OSW_OGL_EGL_H
