Module: wine Branch: master Commit: bfb6119fb3d8c65ed98647a10f12c2820797b8c9 URL: https://gitlab.winehq.org/wine/wine/-/commit/bfb6119fb3d8c65ed98647a10f12c28...
Author: Rémi Bernon rbernon@codeweavers.com Date: Mon Nov 14 22:52:14 2022 +0100
opengl32: Implement wow64 thunk for wglCreatePbufferARB.
---
dlls/opengl32/make_opengl | 1 + dlls/opengl32/unix_thunks.c | 24 +----------------------- dlls/opengl32/unix_wgl.c | 25 +++++++++++++++++++++++++ 3 files changed, 27 insertions(+), 23 deletions(-)
diff --git a/dlls/opengl32/make_opengl b/dlls/opengl32/make_opengl index d41b6e7c054..85e01379b59 100755 --- a/dlls/opengl32/make_opengl +++ b/dlls/opengl32/make_opengl @@ -172,6 +172,7 @@ my %manual_wow64_thunks = "glPathGlyphIndexRangeNV" => 1, "wglCreateContext" => 1, "wglCreateContextAttribsARB" => 1, + "wglCreatePbufferARB" => 1, "wglDeleteContext" => 1, "wglGetProcAddress" => 1, "wglMakeContextCurrentARB" => 1, diff --git a/dlls/opengl32/unix_thunks.c b/dlls/opengl32/unix_thunks.c index 6c8fba0b9f1..e891b59ac3e 100644 --- a/dlls/opengl32/unix_thunks.c +++ b/dlls/opengl32/unix_thunks.c @@ -60644,29 +60644,6 @@ static NTSTATUS wow64_ext_wglChoosePixelFormatARB( void *args ) return status; }
-static NTSTATUS wow64_ext_wglCreatePbufferARB( void *args ) -{ - struct - { - PTR32 hDC; - int iPixelFormat; - int iWidth; - int iHeight; - PTR32 piAttribList; - PTR32 ret; - } *params32 = args; - struct wglCreatePbufferARB_params params = - { - .hDC = ULongToPtr(params32->hDC), - .iPixelFormat = params32->iPixelFormat, - .iWidth = params32->iWidth, - .iHeight = params32->iHeight, - .piAttribList = ULongToPtr(params32->piAttribList), - }; - FIXME( "params32 %p, params %p stub!\n", params32, ¶ms ); - return STATUS_NOT_IMPLEMENTED; -} - static NTSTATUS wow64_ext_wglDestroyPbufferARB( void *args ) { struct @@ -60988,6 +60965,7 @@ extern NTSTATUS wow64_wgl_wglGetProcAddress( void *args ) DECLSPEC_HIDDEN; extern NTSTATUS wow64_wgl_wglMakeCurrent( void *args ) DECLSPEC_HIDDEN; extern NTSTATUS wow64_ext_glPathGlyphIndexRangeNV( void *args ) DECLSPEC_HIDDEN; extern NTSTATUS wow64_ext_wglCreateContextAttribsARB( void *args ) DECLSPEC_HIDDEN; +extern NTSTATUS wow64_ext_wglCreatePbufferARB( void *args ) DECLSPEC_HIDDEN; extern NTSTATUS wow64_ext_wglMakeContextCurrentARB( void *args ) DECLSPEC_HIDDEN;
const unixlib_entry_t __wine_unix_call_wow64_funcs[] = diff --git a/dlls/opengl32/unix_wgl.c b/dlls/opengl32/unix_wgl.c index 8f5e8010ea8..905cd4472be 100644 --- a/dlls/opengl32/unix_wgl.c +++ b/dlls/opengl32/unix_wgl.c @@ -1111,6 +1111,31 @@ NTSTATUS wow64_ext_wglCreateContextAttribsARB( void *args ) return STATUS_SUCCESS; }
+NTSTATUS wow64_ext_wglCreatePbufferARB( void *args ) +{ + struct + { + PTR32 hDC; + GLint iPixelFormat; + GLint iWidth; + GLint iHeight; + PTR32 piAttribList; + PTR32 ret; + } *params32 = args; + struct wglCreatePbufferARB_params params = + { + .hDC = ULongToPtr(params32->hDC), + .iPixelFormat = params32->iPixelFormat, + .iWidth = params32->iWidth, + .iHeight = params32->iHeight, + .piAttribList = ULongToPtr(params32->piAttribList), + }; + NTSTATUS status; + if ((status = ext_wglCreatePbufferARB( ¶ms ))) return status; + params32->ret = (UINT_PTR)params.ret; + return STATUS_SUCCESS; +} + NTSTATUS wow64_wgl_wglDeleteContext( void *args ) { struct