Roderick Colenbrander : wined3d: Check for the presence of wglGetExtensionsStringARB.
Alexandre Julliard
julliard at winehq.org
Mon Mar 30 12:08:46 CDT 2009
Module: wine
Branch: master
Commit: 5d08f3b7051c5b09eedff2ca4365faccc02ce8b6
URL: http://source.winehq.org/git/wine.git/?a=commit;h=5d08f3b7051c5b09eedff2ca4365faccc02ce8b6
Author: Roderick Colenbrander <thunderbird2k at gmail.com>
Date: Sun Mar 29 22:08:42 2009 +0200
wined3d: Check for the presence of wglGetExtensionsStringARB.
---
dlls/wined3d/directx.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c
index aee4efe..3294fff 100644
--- a/dlls/wined3d/directx.c
+++ b/dlls/wined3d/directx.c
@@ -1405,12 +1405,14 @@ static BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) {
/* Make sure there's an active HDC else the WGL extensions will fail */
hdc = pwglGetCurrentDC();
if (hdc) {
- WGL_Extensions = GL_EXTCALL(wglGetExtensionsStringARB(hdc));
- TRACE_(d3d_caps)("WGL_Extensions reported:\n");
+ /* Not all GL drivers might offer WGL extensions e.g. VirtualBox */
+ if(GL_EXTCALL(wglGetExtensionsStringARB))
+ WGL_Extensions = GL_EXTCALL(wglGetExtensionsStringARB(hdc));
if (NULL == WGL_Extensions) {
ERR(" WGL_Extensions returns NULL\n");
} else {
+ TRACE_(d3d_caps)("WGL_Extensions reported:\n");
while (*WGL_Extensions != 0x00) {
const char *Start;
char ThisExtn[256];
More information about the wine-cvs
mailing list