opengl32: Replace the remaining forwards of wgl functions to gdi32.dll in the spec file with wrapper function.
This commit is contained in:
parent
49aa7f9f2f
commit
03c7dfbd4d
|
@ -334,27 +334,27 @@
|
|||
@ stdcall glVertex4sv( ptr ) wine_glVertex4sv
|
||||
@ stdcall glVertexPointer( long long long ptr ) wine_glVertexPointer
|
||||
@ stdcall glViewport( long long long long ) wine_glViewport
|
||||
@ stdcall wglChoosePixelFormat(long ptr) gdi32.ChoosePixelFormat
|
||||
@ stdcall wglCopyContext(long long long) gdi32.wglCopyContext
|
||||
@ stdcall wglChoosePixelFormat(long ptr)
|
||||
@ stdcall wglCopyContext(long long long)
|
||||
@ stdcall wglCreateContext(long)
|
||||
@ stdcall wglCreateLayerContext(long long)
|
||||
@ stdcall wglDeleteContext(long) gdi32.wglDeleteContext
|
||||
@ stdcall wglDeleteContext(long)
|
||||
@ stdcall wglDescribeLayerPlane(long long long long ptr)
|
||||
@ stdcall wglDescribePixelFormat(long long long ptr) gdi32.DescribePixelFormat
|
||||
@ stdcall wglGetCurrentContext() gdi32.wglGetCurrentContext
|
||||
@ stdcall wglGetCurrentDC() gdi32.wglGetCurrentDC
|
||||
@ stdcall wglDescribePixelFormat(long long long ptr)
|
||||
@ stdcall wglGetCurrentContext()
|
||||
@ stdcall wglGetCurrentDC()
|
||||
@ stub wglGetDefaultProcAddress
|
||||
@ stdcall wglGetLayerPaletteEntries(long long long long ptr)
|
||||
@ stdcall wglGetPixelFormat(long) gdi32.GetPixelFormat
|
||||
@ stdcall wglGetPixelFormat(long)
|
||||
@ stdcall wglGetProcAddress(str)
|
||||
@ stdcall wglMakeCurrent(long long)
|
||||
@ stdcall wglRealizeLayerPalette(long long long)
|
||||
@ stdcall wglSetLayerPaletteEntries(long long long long ptr)
|
||||
@ stdcall wglSetPixelFormat(long long ptr) gdi32.SetPixelFormat
|
||||
@ stdcall wglShareLists(long long) gdi32.wglShareLists
|
||||
@ stdcall wglSetPixelFormat(long long ptr)
|
||||
@ stdcall wglShareLists(long long)
|
||||
@ stdcall wglSwapBuffers(long)
|
||||
@ stdcall wglSwapLayerBuffers(long long)
|
||||
@ stdcall wglUseFontBitmapsA(long long long long) gdi32.wglUseFontBitmapsA
|
||||
@ stdcall wglUseFontBitmapsW(long long long long) gdi32.wglUseFontBitmapsW
|
||||
@ stdcall wglUseFontBitmapsA(long long long long)
|
||||
@ stdcall wglUseFontBitmapsW(long long long long)
|
||||
@ stdcall wglUseFontOutlinesA(long long long long long long long ptr)
|
||||
@ stdcall wglUseFontOutlinesW(long long long long long long long ptr)
|
||||
|
|
|
@ -48,8 +48,21 @@ WINE_DECLARE_DEBUG_CHANNEL(opengl);
|
|||
static struct
|
||||
{
|
||||
PROC (WINAPI *p_wglGetProcAddress)(LPCSTR lpszProc);
|
||||
BOOL (WINAPI *p_SetPixelFormat)(HDC hdc, INT iPixelFormat, const PIXELFORMATDESCRIPTOR *ppfd);
|
||||
BOOL (WINAPI *p_wglCopyContext)(HGLRC hglrcSrc, HGLRC hglrcDst, UINT mask);
|
||||
BOOL (WINAPI *p_wglDeleteContext)(HGLRC hglrc);
|
||||
BOOL (WINAPI *p_wglMakeCurrent)(HDC hdc, HGLRC hglrc);
|
||||
BOOL (WINAPI *p_wglShareLists)(HGLRC hglrc1, HGLRC hglrc2);
|
||||
BOOL (WINAPI *p_wglUseFontBitmapsA)(HDC hdc, DWORD first, DWORD count, DWORD listBase);
|
||||
BOOL (WINAPI *p_wglUseFontBitmapsW)(HDC hdc, DWORD first, DWORD count, DWORD listBase);
|
||||
HDC (WINAPI *p_wglGetCurrentDC)(void);
|
||||
HGLRC (WINAPI *p_wglCreateContext)(HDC hdc);
|
||||
HGLRC (WINAPI *p_wglGetCurrentContext)(void);
|
||||
INT (WINAPI *p_ChoosePixelFormat)(HDC hdc, const PIXELFORMATDESCRIPTOR* ppfd);
|
||||
INT (WINAPI *p_DescribePixelFormat)(HDC hdc, INT iPixelFormat, UINT nBytes, LPPIXELFORMATDESCRIPTOR ppfd);
|
||||
INT (WINAPI *p_GetPixelFormat)(HDC hdc);
|
||||
|
||||
/* Interal WGL function */
|
||||
void (WINAPI *p_wglGetIntegerv)(GLenum pname, GLint* params);
|
||||
void (WINAPI *p_wglFinish)(void);
|
||||
void (WINAPI *p_wglFlush)(void);
|
||||
|
@ -115,6 +128,31 @@ void enter_gl(void)
|
|||
|
||||
const GLubyte * WINAPI wine_glGetString( GLenum name );
|
||||
|
||||
/***********************************************************************
|
||||
* wglSetPixelFormat(OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglSetPixelFormat( HDC hdc, INT iPixelFormat,
|
||||
const PIXELFORMATDESCRIPTOR *ppfd)
|
||||
{
|
||||
return wine_wgl.p_SetPixelFormat(hdc, iPixelFormat, ppfd);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglCopyContext (OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglCopyContext(HGLRC hglrcSrc, HGLRC hglrcDst, UINT mask)
|
||||
{
|
||||
return wine_wgl.p_wglCopyContext(hglrcSrc, hglrcDst, mask);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglDeleteContext (OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglDeleteContext(HGLRC hglrc)
|
||||
{
|
||||
return wine_wgl.p_wglDeleteContext(hglrc);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglMakeCurrent (OPENGL32.@)
|
||||
*/
|
||||
|
@ -123,6 +161,38 @@ BOOL WINAPI wglMakeCurrent(HDC hdc, HGLRC hglrc)
|
|||
return wine_wgl.p_wglMakeCurrent(hdc, hglrc);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglShareLists (OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglShareLists(HGLRC hglrc1, HGLRC hglrc2)
|
||||
{
|
||||
return wine_wgl.p_wglShareLists(hglrc1, hglrc2);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglUseFontBitmapsA (OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglUseFontBitmapsA(HDC hdc, DWORD first, DWORD count, DWORD listBase)
|
||||
{
|
||||
return wine_wgl.p_wglUseFontBitmapsA(hdc, first, count, listBase);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglUseFontBitmapsW (OPENGL32.@)
|
||||
*/
|
||||
BOOL WINAPI wglUseFontBitmapsW(HDC hdc, DWORD first, DWORD count, DWORD listBase)
|
||||
{
|
||||
return wine_wgl.p_wglUseFontBitmapsW(hdc, first, count, listBase);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglGetCurrentDC (OPENGL32.@)
|
||||
*/
|
||||
HDC WINAPI wglGetCurrentDC(void)
|
||||
{
|
||||
return wine_wgl.p_wglGetCurrentDC();
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglCreateContext (OPENGL32.@)
|
||||
*/
|
||||
|
@ -131,6 +201,38 @@ HGLRC WINAPI wglCreateContext(HDC hdc)
|
|||
return wine_wgl.p_wglCreateContext(hdc);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglGetCurrentContext (OPENGL32.@)
|
||||
*/
|
||||
HGLRC WINAPI wglGetCurrentContext(void)
|
||||
{
|
||||
return wine_wgl.p_wglGetCurrentContext();
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglChoosePixelFormat (OPENGL32.@)
|
||||
*/
|
||||
INT WINAPI wglChoosePixelFormat(HDC hdc, const PIXELFORMATDESCRIPTOR* ppfd)
|
||||
{
|
||||
return wine_wgl.p_ChoosePixelFormat(hdc, ppfd);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglDescribePixelFormat (OPENGL32.@)
|
||||
*/
|
||||
INT WINAPI wglDescribePixelFormat(HDC hdc, INT iPixelFormat, UINT nBytes,
|
||||
LPPIXELFORMATDESCRIPTOR ppfd)
|
||||
{
|
||||
return wine_wgl.p_DescribePixelFormat(hdc, iPixelFormat, nBytes, ppfd);
|
||||
}
|
||||
/***********************************************************************
|
||||
* wglGetPixelFormat (OPENGL32.@)
|
||||
*/
|
||||
INT WINAPI wglGetPixelFormat(HDC hdc)
|
||||
{
|
||||
return wine_wgl.p_GetPixelFormat(hdc);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* wglCreateLayerContext (OPENGL32.@)
|
||||
*/
|
||||
|
@ -735,8 +837,19 @@ static BOOL process_attach(void)
|
|||
wine_tsx11_unlock_ptr = (void *)GetProcAddress( mod_x11, "wine_tsx11_unlock" );
|
||||
|
||||
wine_wgl.p_wglGetProcAddress = (void *)GetProcAddress(mod_gdi32, "wglGetProcAddress");
|
||||
wine_wgl.p_SetPixelFormat = (void *)GetProcAddress(mod_gdi32, "SetPixelFormat");
|
||||
wine_wgl.p_wglCopyContext = (void *)GetProcAddress(mod_gdi32, "wglCopyContext");
|
||||
wine_wgl.p_wglDeleteContext = (void *)GetProcAddress(mod_gdi32, "wglDeleteContext");
|
||||
wine_wgl.p_wglMakeCurrent = (void *)GetProcAddress(mod_gdi32, "wglMakeCurrent");
|
||||
wine_wgl.p_wglShareLists = (void *)GetProcAddress(mod_gdi32, "wglShareLists");
|
||||
wine_wgl.p_wglUseFontBitmapsA = (void *)GetProcAddress(mod_gdi32, "wglUseFontBitmapsA");
|
||||
wine_wgl.p_wglUseFontBitmapsW = (void *)GetProcAddress(mod_gdi32, "wglUseFontBitmapsW");
|
||||
wine_wgl.p_wglGetCurrentDC = (void *)GetProcAddress(mod_gdi32, "wglGetCurrentDC");
|
||||
wine_wgl.p_wglCreateContext = (void *)GetProcAddress(mod_gdi32, "wglCreateContext");
|
||||
wine_wgl.p_wglGetCurrentContext = (void *)GetProcAddress(mod_gdi32, "wglGetCurrentContext");
|
||||
wine_wgl.p_ChoosePixelFormat = (void *)GetProcAddress(mod_gdi32, "ChoosePixelFormat");
|
||||
wine_wgl.p_DescribePixelFormat = (void *)GetProcAddress(mod_gdi32, "DescribePixelFormat");
|
||||
wine_wgl.p_GetPixelFormat = (void *)GetProcAddress(mod_gdi32, "GetPixelFormat");
|
||||
|
||||
/* Interal WGL function */
|
||||
wine_wgl.p_wglGetIntegerv = (void *)wine_wgl.p_wglGetProcAddress("wglGetIntegerv");
|
||||
|
|
Loading…
Reference in New Issue