fbsdk/fbsdk-opengl.h Source File
Go to the documentation of this file. 1 #ifndef _FBSDK_OPENGL_H_
2 #define _FBSDK_OPENGL_H_
39 #if defined(KARCH_ENV_WIN32)
43 #define CALLBACK __stdcall
44 #define WINAPI __stdcall
45 #define DECLSPEC_IMPORT __declspec(dllimport)
46 #define WINGDIAPI DECLSPEC_IMPORT
47 #define APIENTRY WINAPI
49 #ifndef _WCHAR_T_DEFINED
50 #ifndef KARCH_ENV_MING32
51 typedef unsigned short wchar_t;
53 #define _WCHAR_T_DEFINED
57 #define glDeleteTextures glDeleteTexturesEXT
58 #define glGenTextures glGenTexturesEXT
59 #define glBindTexture glBindTextureEXT
60 #define glCopyTexImage2D glCopyTexImage2DEXT
61 #define glCopyTexSubImage2D glCopyTexSubImage2DEXT
62 #define glTexSubImage2D glTexSubImage2DEXT
63 #define glIsTexture glIsTextureEXT
64 #define glCopyTexImage2D glCopyTexImage2DEXT
65 #define GL_BGRA_EXT GL_BGRA // On SGI only this is not an extension
66 #define GL_BGR_EXT GL_BGR // On SGI only this is not an extension
73 #if defined(KARCH_ENV_MACOSX)
74 #include <OpenGl/gl.h>
75 #include <OpenGl/glu.h>
81 #if defined(KARCH_ENV_WIN32) || defined(KARCH_ENV_WIN64)
82 #if defined(KARCH_ENV_MING32)
86 #define GL_BGR GL_BGR_EXT
87 #define GL_BGRA GL_BGRA_EXT
89 #define GL_POST_COLOR_MATRIX_COLOR_TABLE_EXT 0x80D2 // glEnable
92 #define GL_ABGR_EXT 0x8000
96 #ifndef GL_LIGHT_MODEL_COLOR_CONTROL_EXT
97 #define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8 // glLightModel OpenGL 1.2
100 #ifndef GL_SINGLE_COLOR_EXT
101 #define GL_SINGLE_COLOR_EXT 0x81F9 // glLightModel OpenGL 1.2
104 #ifndef GL_SEPARATE_SPECULAR_COLOR_EXT
105 #define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA // glLightModel OpenGL 1.2
108 #define GL_DISPLAY_CGP 0x6001
109 #define GL_GLTARGET_CGP 0x6003
112 #if defined(KARCH_ENV_LINUX)
113 #include <GL/glext.h>
114 #define GL_POST_COLOR_MATRIX_COLOR_TABLE_EXT GL_POST_COLOR_MATRIX_COLOR_TABLE
117 #if defined(KARCH_ENV_IRIX)
118 #define GL_POST_COLOR_MATRIX_COLOR_TABLE_EXT GL_POST_COLOR_MATRIX_COLOR_TABLE
121 #if defined(KARCH_ENV_MACOSX)
122 #include <OpenGl/glext.h>
123 #define GL_POST_COLOR_MATRIX_COLOR_TABLE_EXT GL_POST_COLOR_MATRIX_COLOR_TABLE
126 #ifndef GL_LIGHT_MODEL_COLOR_CONTROL
127 #define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8
130 #ifndef GL_SEPARATE_SPECULAR_COLOR
131 #define GL_SEPARATE_SPECULAR_COLOR 0x81FA
134 #ifndef GL_EXT_422_pixels
135 #define GL_422_EXT 0x80cc
138 #ifndef GL_CLAMP_TO_EDGE
139 #define GL_CLAMP_TO_EDGE 0x812F