Date: Wed, 28 Apr 2004 16:52:41 -0400
From: "Damien A" Subject: testdyngl fix The test program you included in the latest version of SDL crashes on startup in Window (XP). The reason for this is that OpenGL functions on Windows use the __stdcall calling convention, not the C convention. Placing APIENTRY infront of the * operator solves this problem. --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%40886
This commit is contained in:
parent
e930e4a0da
commit
2ca2c6c186
1 changed files with 17 additions and 17 deletions
|
@ -39,23 +39,23 @@ void* get_funcaddr(const char* p)
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
void(*glBegin)(GLenum);
|
void(APIENTRY*glBegin)(GLenum);
|
||||||
void(*glEnd)();
|
void(APIENTRY*glEnd)();
|
||||||
void(*glVertex3f)(GLfloat, GLfloat, GLfloat);
|
void(APIENTRY*glVertex3f)(GLfloat, GLfloat, GLfloat);
|
||||||
void(*glClearColor)(GLfloat, GLfloat, GLfloat, GLfloat);
|
void(APIENTRY*glClearColor)(GLfloat, GLfloat, GLfloat, GLfloat);
|
||||||
void(*glClear)(GLbitfield);
|
void(APIENTRY*glClear)(GLbitfield);
|
||||||
void(*glDisable)(GLenum);
|
void(APIENTRY*glDisable)(GLenum);
|
||||||
void(*glEnable)(GLenum);
|
void(APIENTRY*glEnable)(GLenum);
|
||||||
void(*glColor4ub)(GLubyte,GLubyte,GLubyte,GLubyte);
|
void(APIENTRY*glColor4ub)(GLubyte,GLubyte,GLubyte,GLubyte);
|
||||||
void(*glPointSize)(GLfloat);
|
void(APIENTRY*glPointSize)(GLfloat);
|
||||||
void(*glHint)(GLenum,GLenum);
|
void(APIENTRY*glHint)(GLenum,GLenum);
|
||||||
void(*glBlendFunc)(GLenum,GLenum);
|
void(APIENTRY*glBlendFunc)(GLenum,GLenum);
|
||||||
void(*glMatrixMode)(GLenum);
|
void(APIENTRY*glMatrixMode)(GLenum);
|
||||||
void(*glLoadIdentity)();
|
void(APIENTRY*glLoadIdentity)();
|
||||||
void(*glOrtho)(GLdouble,GLdouble,GLdouble,GLdouble,GLdouble,GLdouble);
|
void(APIENTRY*glOrtho)(GLdouble,GLdouble,GLdouble,GLdouble,GLdouble,GLdouble);
|
||||||
void(*glRotatef)(GLfloat,GLfloat,GLfloat,GLfloat);
|
void(APIENTRY*glRotatef)(GLfloat,GLfloat,GLfloat,GLfloat);
|
||||||
void(*glViewport)(GLint,GLint,GLsizei,GLsizei);
|
void(APIENTRY*glViewport)(GLint,GLint,GLsizei,GLsizei);
|
||||||
void(*glFogf)(GLenum,GLfloat);
|
void(APIENTRY*glFogf)(GLenum,GLfloat);
|
||||||
}
|
}
|
||||||
glfuncs;
|
glfuncs;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue