2012-11-15 00:39:56 +01:00
|
|
|
#pragma once
|
2014-03-11 17:36:17 +01:00
|
|
|
#ifndef _WIN32
|
|
|
|
|
#include <GL/glew.h>
|
|
|
|
|
#endif
|
2012-11-15 00:39:56 +01:00
|
|
|
|
2013-11-24 10:17:18 +01:00
|
|
|
#ifdef _WIN32
|
2014-08-29 00:49:26 +02:00
|
|
|
#include <Windows.h>
|
2014-05-01 19:29:28 +02:00
|
|
|
#include "GL/gl.h"
|
2016-03-18 15:13:52 +01:00
|
|
|
#include <glext.h>
|
2013-06-30 10:46:29 +02:00
|
|
|
typedef BOOL (WINAPI* PFNWGLSWAPINTERVALEXTPROC) (int interval);
|
|
|
|
|
|
|
|
|
|
#define OPENGL_PROC(p, n) extern p gl##n
|
2017-08-13 19:41:55 +02:00
|
|
|
#define WGL_PROC(p, n) extern p wgl##n
|
2013-06-30 10:46:29 +02:00
|
|
|
#define OPENGL_PROC2(p, n, tn) OPENGL_PROC(p, n)
|
2014-04-27 19:28:03 +02:00
|
|
|
#include "GLProcTable.h"
|
2012-11-15 00:39:56 +01:00
|
|
|
#undef OPENGL_PROC
|
2017-08-13 19:41:55 +02:00
|
|
|
#undef WGL_PROC
|
2013-06-30 10:46:29 +02:00
|
|
|
#undef OPENGL_PROC2
|
|
|
|
|
|
2014-05-01 19:29:28 +02:00
|
|
|
#elif defined(__APPLE__)
|
2014-04-29 00:51:49 +02:00
|
|
|
#include <OpenGL/gl.h>
|
|
|
|
|
#include <OpenGL/glu.h>
|
|
|
|
|
|
2014-02-21 17:13:57 +01:00
|
|
|
#else
|
2014-04-29 00:51:49 +02:00
|
|
|
#include <GL/gl.h>
|
2019-11-20 16:53:41 +01:00
|
|
|
#ifdef HAVE_X11
|
|
|
|
|
#include <GL/glxew.h>
|
2014-02-21 17:13:57 +01:00
|
|
|
#include <GL/glx.h>
|
|
|
|
|
#include <GL/glxext.h>
|
|
|
|
|
#endif
|
2019-11-20 16:53:41 +01:00
|
|
|
#endif
|
2014-02-21 17:13:57 +01:00
|
|
|
|
2016-06-12 15:37:30 +02:00
|
|
|
#ifndef GL_TEXTURE_BUFFER_BINDING
|
|
|
|
|
//During spec release, this enum was removed during upgrade from ARB equivalent
|
|
|
|
|
//See https://www.khronos.org/bugzilla/show_bug.cgi?id=844
|
|
|
|
|
#define GL_TEXTURE_BUFFER_BINDING 0x8C2A
|
|
|
|
|
#endif
|
|
|
|
|
|
2015-10-04 00:45:26 +02:00
|
|
|
namespace gl
|
|
|
|
|
{
|
|
|
|
|
void init();
|
2017-08-13 19:41:55 +02:00
|
|
|
void set_swapinterval(int interval);
|
2015-10-04 00:45:26 +02:00
|
|
|
}
|