From: José Fonseca Date: Wed, 8 Feb 2012 15:46:28 +0000 (+0000) Subject: st/wgl: Fix argument of stw_pixelformat_get_info(). X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9ffc8ea8f4cfa15115a93039cc7099f0fd597fe3;p=mesa.git st/wgl: Fix argument of stw_pixelformat_get_info(). stw_pixelformat_get_info takes zero based index, not a 1 based pixel format number. --- diff --git a/src/gallium/state_trackers/wgl/stw_ext_pbuffer.c b/src/gallium/state_trackers/wgl/stw_ext_pbuffer.c index 2c3555d5dbf..085591a5560 100644 --- a/src/gallium/state_trackers/wgl/stw_ext_pbuffer.c +++ b/src/gallium/state_trackers/wgl/stw_ext_pbuffer.c @@ -85,7 +85,7 @@ wglCreatePbufferARB(HDC hCurrentDC, PIXELFORMATDESCRIPTOR pfd; BOOL bRet; - info = stw_pixelformat_get_info(iPixelFormat); + info = stw_pixelformat_get_info(iPixelFormat - 1); if (!info) { SetLastError(ERROR_INVALID_PIXEL_FORMAT); return 0;