forked from 0ad/0ad
new: windows-specific opengl header (included by ogl.h)
This was SVN commit r391.
This commit is contained in:
parent
8e6e179187
commit
5747fe33b0
51
source/lib/sysdep/win/wgl.h
Executable file
51
source/lib/sysdep/win/wgl.h
Executable file
@ -0,0 +1,51 @@
|
||||
// RAGE! Win32 OpenGL headers are full of crap we have to emulate
|
||||
// (must not include windows.h)
|
||||
|
||||
#ifndef _WIN32
|
||||
#error "do not include if not compiling for Windows"
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef WINGDIAPI
|
||||
#define WINGDIAPI __declspec(dllimport)
|
||||
#endif
|
||||
#ifndef CALLBACK
|
||||
#define CALLBACK __stdcall
|
||||
#endif
|
||||
#ifndef APIENTRY
|
||||
#define APIENTRY __stdcall
|
||||
#endif
|
||||
#ifndef WINAPI
|
||||
#define WINAPI __stdcall
|
||||
#endif
|
||||
|
||||
|
||||
typedef void VOID;
|
||||
typedef void* LPVOID;
|
||||
typedef int BOOL;
|
||||
typedef unsigned short USHORT;
|
||||
typedef unsigned int UINT;
|
||||
typedef unsigned long DWORD;
|
||||
typedef int INT32;
|
||||
typedef __int64 INT64;
|
||||
typedef float FLOAT;
|
||||
typedef const char* LPCSTR;
|
||||
typedef void* HANDLE;
|
||||
typedef int(*PROC)(void);
|
||||
#define DECLARE_HANDLE(name) typedef HANDLE name
|
||||
DECLARE_HANDLE(HDC);
|
||||
DECLARE_HANDLE(HGLRC);
|
||||
|
||||
typedef unsigned short wchar_t; // for glu.h
|
||||
|
||||
WINGDIAPI BOOL WINAPI wglCopyContext(HGLRC, HGLRC, UINT);
|
||||
WINGDIAPI HGLRC WINAPI wglCreateContext(HDC);
|
||||
WINGDIAPI HGLRC WINAPI wglCreateLayerContext(HDC, int);
|
||||
WINGDIAPI BOOL WINAPI wglDeleteContext(HGLRC);
|
||||
WINGDIAPI HGLRC WINAPI wglGetCurrentContext(VOID);
|
||||
WINGDIAPI HDC WINAPI wglGetCurrentDC(VOID);
|
||||
WINGDIAPI PROC WINAPI wglGetProcAddress(LPCSTR);
|
||||
WINGDIAPI BOOL WINAPI wglMakeCurrent(HDC, HGLRC);
|
||||
WINGDIAPI BOOL WINAPI wglShareLists(HGLRC, HGLRC);
|
||||
WINGDIAPI BOOL WINAPI wglUseFontBitmapsA(HDC, DWORD, DWORD, DWORD);
|
||||
WINGDIAPI BOOL WINAPI wglUseFontBitmapsW(HDC, DWORD, DWORD, DWORD);
|
Loading…
Reference in New Issue
Block a user