Module: wine
Branch: master
Commit: 9a319f28578c01c4d2fb937ecebd734476986859
URL: http://source.winehq.org/git/wine.git/?a=commit;h=9a319f28578c01c4d2fb937ec…
Author: Chris Robinson <chris.kcat(a)gmail.com>
Date: Sun Aug 5 10:50:45 2007 -0700
wined3d: Properly setup DevModeW before using it.
---
dlls/wined3d/directx.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c
index 7da3ef2..a0d7dd1 100644
--- a/dlls/wined3d/directx.c
+++ b/dlls/wined3d/directx.c
@@ -1070,6 +1070,8 @@ static UINT WINAPI IWineD3DImpl_GetAdapterModeCount(IWineD3D *iface, UINT Ad
if (!DEBUG_SINGLE_MODE) {
DEVMODEW DevModeW;
+ ZeroMemory(&DevModeW, sizeof(DevModeW));
+ DevModeW.dmSize = sizeof(DevModeW);
while (EnumDisplaySettingsExW(NULL, j, &DevModeW, 0)) {
j++;
switch (Format)
@@ -1125,6 +1127,9 @@ static HRESULT WINAPI IWineD3DImpl_EnumAdapterModes(IWineD3D *iface, UINT Adapte
int i = 0;
int j = 0;
+ ZeroMemory(&DevModeW, sizeof(DevModeW));
+ DevModeW.dmSize = sizeof(DevModeW);
+
/* If we are filtering to a specific format (D3D9), then need to skip
all unrelated modes, but if mode is irrelevant (D3D8), then we can
just count through the ones with valid bit depths */
@@ -1222,6 +1227,9 @@ static HRESULT WINAPI IWineD3DImpl_GetAdapterDisplayMode(IWineD3D *iface, UINT A
int bpp = 0;
DEVMODEW DevModeW;
+ ZeroMemory(&DevModeW, sizeof(DevModeW));
+ DevModeW.dmSize = sizeof(DevModeW);
+
EnumDisplaySettingsExW(NULL, (DWORD)-1, &DevModeW, 0);
pMode->Width = DevModeW.dmPelsWidth;
pMode->Height = DevModeW.dmPelsHeight;
Module: wine
Branch: master
Commit: b4c11e30335f2320b81a2158af06af5ae2a6be21
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b4c11e30335f2320b81a2158a…
Author: Chris Robinson <chris.kcat(a)gmail.com>
Date: Sat Aug 4 11:12:36 2007 -0700
winex11: Properly handle WGL_PBUFFER_LOST_ARB.
---
dlls/winex11.drv/opengl.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c
index 91acd3b..d4ed729 100644
--- a/dlls/winex11.drv/opengl.c
+++ b/dlls/winex11.drv/opengl.c
@@ -2279,7 +2279,11 @@ static GLboolean WINAPI X11DRV_wglQueryPbufferARB(HPBUFFERARB hPbuffer, int iAtt
break;
case WGL_PBUFFER_LOST_ARB:
- FIXME("unsupported WGL_PBUFFER_LOST_ARB (need glXSelectEvent/GLX_DAMAGED work)\n");
+ /* GLX Pbuffers cannot be lost by default. We can support this by
+ * setting GLX_PRESERVED_CONTENTS to False and using glXSelectEvent
+ * to receive pixel buffer clobber events, however that may or may
+ * not give any benefit */
+ *piValue = GL_FALSE;
break;
case WGL_TEXTURE_FORMAT_ARB: