/
apistubs.c
40 lines (31 loc) · 1.47 KB
/
apistubs.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel
* FILE: lib/opengl32/apistubs.c
* PURPOSE: OpenGL32 lib, glXXX functions
*/
#include "opengl32.h"
#ifndef __i386__
#define USE_GL_FUNC(name, proto_args, call_args, offset, stack) \
void GLAPIENTRY gl##name proto_args \
{ \
const GLDISPATCHTABLE * Dispatch = IntGetCurrentDispatchTable(); \
if (!Dispatch) \
return; \
Dispatch->name call_args ; \
}
#define USE_GL_FUNC_RET(name, ret_type, proto_args, call_args, offset, stack) \
ret_type GLAPIENTRY gl##name proto_args \
{ \
const GLDISPATCHTABLE * Dispatch = IntGetCurrentDispatchTable(); \
if (!Dispatch) \
return 0; \
return Dispatch->name call_args ; \
}
#include "glfuncs.h"
#endif //__i386__
/* Unknown debug function */
GLint GLAPIENTRY glDebugEntry(GLint unknown1, GLint unknown2)
{
return 0;
}