2011-03-24 14:35:24 +00:00
|
|
|
#ifndef __GL_VIDEGL_H__
|
|
|
|
#define __GL_VIDEGL_H__
|
2011-02-06 20:56:39 +00:00
|
|
|
|
|
|
|
#include "quakedef.h"
|
2018-03-24 04:02:09 +00:00
|
|
|
#define NativeWindowType EGLNativeWindowType //for old egl versions
|
2011-02-06 20:56:39 +00:00
|
|
|
#include <EGL/egl.h>
|
2016-12-13 11:50:15 +00:00
|
|
|
#ifndef _WIN32
|
|
|
|
#include <dlfcn.h>
|
|
|
|
#endif
|
2011-02-06 20:56:39 +00:00
|
|
|
|
2018-03-24 04:02:09 +00:00
|
|
|
#ifndef EGL_PLATFORM_X11_KHR
|
|
|
|
#define EGL_PLATFORM_X11_KHR 0x31D5 //EGL_KHR_platform_x11
|
|
|
|
#define EGL_PLATFORM_X11_SCREEN_KHR 0x31D6 //an attrib
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef EGL_PLATFORM_WAYLAND_KHR
|
|
|
|
#define EGL_PLATFORM_WAYLAND_KHR 0x31D8 //EGL_KHR_platform_wayland
|
|
|
|
#endif
|
|
|
|
|
2018-03-25 09:36:14 +00:00
|
|
|
#ifndef EGL_PLATFORM_WIN32
|
|
|
|
#define EGL_PLATFORM_WIN32 0 //no meaningful value.
|
|
|
|
#endif
|
|
|
|
|
2011-02-06 20:56:39 +00:00
|
|
|
void *EGL_Proc(char *f);
|
|
|
|
void EGL_UnloadLibrary(void);
|
|
|
|
qboolean EGL_LoadLibrary(char *driver);
|
|
|
|
void EGL_Shutdown(void);
|
2014-03-30 00:39:37 +00:00
|
|
|
void EGL_SwapBuffers (void);
|
2019-07-16 02:59:12 +00:00
|
|
|
|
|
|
|
qboolean EGL_InitDisplay (rendererstate_t *info, int eglplat, void *ndpy, EGLNativeDisplayType dpyid, EGLConfig *outconfig);
|
|
|
|
qboolean EGL_InitWindow (rendererstate_t *info, int eglplat, void *nwindow, EGLNativeWindowType windowid, EGLConfig cfg);
|
|
|
|
//qboolean EGL_Init (rendererstate_t *info, unsigned char *palette, int eglplatform, void *nwindow, void *ndpy, EGLNativeWindowType owindow, EGLNativeDisplayType odpy);
|
|
|
|
|
|
|
|
//once you've created an egl display and got an egl config, some windowing systems require querying said egl config to create the window properly.
|
|
|
|
extern EGLDisplay egldpy;
|
|
|
|
extern EGLBoolean (EGLAPIENTRY *qeglGetConfigAttrib)(EGLDisplay dpy, EGLConfig config, EGLint attribute, EGLint *value);
|
2011-02-06 20:56:39 +00:00
|
|
|
|
|
|
|
#endif
|