Huw Davies : x11drv: Get the visual for the GLXPixmap from the
current pixel format.
Alexandre Julliard
julliard at wine.codeweavers.com
Sat Dec 17 05:37:46 CST 2005
Module: wine
Branch: refs/heads/master
Commit: 8b7098794d33cec06124a37dcdc33249a33a0b5c
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=8b7098794d33cec06124a37dcdc33249a33a0b5c
Author: Huw Davies <huw at codeweavers.com>
Date: Fri Dec 16 19:29:52 2005 +0100
x11drv: Get the visual for the GLXPixmap from the current pixel format.
---
dlls/x11drv/opengl.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/dlls/x11drv/opengl.c b/dlls/x11drv/opengl.c
index 3a400c1..c119e7c 100644
--- a/dlls/x11drv/opengl.c
+++ b/dlls/x11drv/opengl.c
@@ -588,13 +588,17 @@ XID create_glxpixmap(X11DRV_PDEVICE *phy
XVisualInfo *vis;
XVisualInfo template;
int num;
+ GLXFBConfig *cfgs;
wine_tsx11_lock();
- template.visualid = XVisualIDFromVisual(visual);
+ cfgs = pglXGetFBConfigs(gdi_display, DefaultScreen(gdi_display), &num);
+ pglXGetFBConfigAttrib(gdi_display, cfgs[physDev->current_pf - 1], GLX_VISUAL_ID, (int *)&template.visualid);
+
vis = XGetVisualInfo(gdi_display, VisualIDMask, &template, &num);
ret = pglXCreateGLXPixmap(gdi_display, vis, physDev->bitmap->pixmap);
XFree(vis);
+ XFree(cfgs);
wine_tsx11_unlock();
TRACE("return %lx\n", ret);
return ret;
More information about the wine-cvs
mailing list