2016-07-09 02:18:40 +00:00
|
|
|
#ifndef BBGE_RENDERBASE_H
|
|
|
|
#define BBGE_RENDERBASE_H
|
|
|
|
|
|
|
|
#include "SDL.h"
|
|
|
|
|
2016-09-26 02:13:28 +00:00
|
|
|
// Define this before including GL headers to avoid pulling in windows.h
|
|
|
|
#if defined(_WIN32) && !defined(APIENTRY)
|
|
|
|
# define APIENTRY __stdcall
|
|
|
|
#endif
|
|
|
|
|
2016-07-09 02:18:40 +00:00
|
|
|
#define GL_GLEXT_LEGACY 1
|
2017-02-09 20:17:21 +00:00
|
|
|
#include <GL/gl.h>
|
|
|
|
#include <GL/glext.h>
|
2016-07-09 02:18:40 +00:00
|
|
|
|
|
|
|
#ifdef _WINDOWS_
|
|
|
|
#error windows.h was included! euuugh!
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef APIENTRY
|
|
|
|
#undef APIENTRY
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef WINGDIAPI
|
|
|
|
#undef WINGDIAPI
|
|
|
|
#endif
|
|
|
|
|
2016-09-26 02:13:28 +00:00
|
|
|
extern PFNGLGENERATEMIPMAPEXTPROC glGenerateMipmapEXT;
|
|
|
|
|
|
|
|
// GL_ARB_shader_objects
|
|
|
|
extern PFNGLCREATEPROGRAMOBJECTARBPROC glCreateProgramObjectARB;
|
|
|
|
extern PFNGLDELETEOBJECTARBPROC glDeleteObjectARB;
|
|
|
|
extern PFNGLUSEPROGRAMOBJECTARBPROC glUseProgramObjectARB;
|
|
|
|
extern PFNGLCREATESHADEROBJECTARBPROC glCreateShaderObjectARB;
|
|
|
|
extern PFNGLSHADERSOURCEARBPROC glShaderSourceARB;
|
|
|
|
extern PFNGLCOMPILESHADERARBPROC glCompileShaderARB;
|
|
|
|
extern PFNGLGETOBJECTPARAMETERIVARBPROC glGetObjectParameterivARB;
|
|
|
|
extern PFNGLATTACHOBJECTARBPROC glAttachObjectARB;
|
|
|
|
extern PFNGLGETINFOLOGARBPROC glGetInfoLogARB;
|
|
|
|
extern PFNGLLINKPROGRAMARBPROC glLinkProgramARB;
|
|
|
|
extern PFNGLGETUNIFORMLOCATIONARBPROC glGetUniformLocationARB;
|
|
|
|
extern PFNGLGETACTIVEUNIFORMARBPROC glGetActiveUniformARB;
|
|
|
|
extern PFNGLUNIFORM1FVARBPROC glUniform1fvARB ;
|
|
|
|
extern PFNGLUNIFORM2FVARBPROC glUniform2fvARB;
|
|
|
|
extern PFNGLUNIFORM3FVARBPROC glUniform3fvARB;
|
|
|
|
extern PFNGLUNIFORM4FVARBPROC glUniform4fvARB;
|
|
|
|
extern PFNGLUNIFORM1IVARBPROC glUniform1ivARB;
|
|
|
|
extern PFNGLUNIFORM2IVARBPROC glUniform2ivARB;
|
|
|
|
extern PFNGLUNIFORM3IVARBPROC glUniform3ivARB;
|
|
|
|
extern PFNGLUNIFORM4IVARBPROC glUniform4ivARB;
|
|
|
|
|
|
|
|
extern PFNGLISRENDERBUFFEREXTPROC glIsRenderbufferEXT;
|
|
|
|
extern PFNGLBINDRENDERBUFFEREXTPROC glBindRenderbufferEXT;
|
|
|
|
extern PFNGLDELETERENDERBUFFERSEXTPROC glDeleteRenderbuffersEXT;
|
|
|
|
extern PFNGLGENRENDERBUFFERSEXTPROC glGenRenderbuffersEXT;
|
|
|
|
extern PFNGLRENDERBUFFERSTORAGEEXTPROC glRenderbufferStorageEXT;
|
|
|
|
extern PFNGLGETRENDERBUFFERPARAMETERIVEXTPROC glGetRenderbufferParameterivEXT;
|
|
|
|
extern PFNGLISFRAMEBUFFEREXTPROC glIsFramebufferEXT;
|
|
|
|
extern PFNGLBINDFRAMEBUFFEREXTPROC glBindFramebufferEXT;
|
|
|
|
extern PFNGLDELETEFRAMEBUFFERSEXTPROC glDeleteFramebuffersEXT;
|
|
|
|
extern PFNGLGENFRAMEBUFFERSEXTPROC glGenFramebuffersEXT;
|
|
|
|
extern PFNGLCHECKFRAMEBUFFERSTATUSEXTPROC glCheckFramebufferStatusEXT;
|
|
|
|
extern PFNGLFRAMEBUFFERTEXTURE1DEXTPROC glFramebufferTexture1DEXT;
|
|
|
|
extern PFNGLFRAMEBUFFERTEXTURE2DEXTPROC glFramebufferTexture2DEXT;
|
|
|
|
extern PFNGLFRAMEBUFFERTEXTURE3DEXTPROC glFramebufferTexture3DEXT;
|
|
|
|
extern PFNGLFRAMEBUFFERRENDERBUFFEREXTPROC glFramebufferRenderbufferEXT;
|
|
|
|
extern PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC glGetFramebufferAttachmentParameterivEXT;
|
|
|
|
|
|
|
|
|
2016-07-09 02:18:40 +00:00
|
|
|
|
|
|
|
#endif
|