- debug: add provision for naming threads. allows adding current thread name to log messages and displays their names in the debugger. - replaced various if(err < 0) complain() sequences with new variants of CHECK_ERR (see lib.h) - fixes to mmgr/VC debug alloc enable code - improved h_mgr error reporting (now complains when h_free fails) - US -> UK english (partial) - fix tex_load double-free bug - move win32 mouse cursor code into sysdep - error dialog is now topmost to make sure it's visible (was a problem) - handle WM_QUIT before displaying error dialog (makes sure it's shown) also as in previous 3 revisions. This was SVN commit r2588.
53 lines
1.4 KiB
C
Executable File
53 lines
1.4 KiB
C
Executable File
// RAGE! Win32 OpenGL headers are full of crap we have to emulate
|
|
// (must not include windows.h)
|
|
|
|
#if !OS_WIN
|
|
#error "wgl.h: 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
|
|
|
|
#ifndef DECLARE_HANDLE
|
|
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);
|
|
#endif
|
|
|
|
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);
|