wgl: Add WGL_SWAP_METHOD_ARB support.

This commit is contained in:
Roderick Colenbrander 2009-05-16 00:00:24 +02:00 committed by Alexandre Julliard
parent c4e6018320
commit cc96ce438a
2 changed files with 18 additions and 0 deletions

View File

@ -730,6 +730,12 @@ static int ConvertAttribWGLtoGLX(const int* iWGLAttr, int* oGLXAttr, Wine_GLPBuf
TRACE("pAttr[%d] = WGL_SUPPORT_OPENGL_ARB: %d\n", cur, pop);
break;
case WGL_SWAP_METHOD_ARB:
pop = iWGLAttr[++cur];
/* For now we ignore this and just return SWAP_EXCHANGE */
TRACE("pAttr[%d] = WGL_SWAP_METHOD_ARB: %#x\n", cur, pop);
break;
case WGL_PBUFFER_LARGEST_ARB:
pop = iWGLAttr[++cur];
PUSH2(oGLXAttr, GLX_LARGEST_PBUFFER, pop);
@ -2901,6 +2907,14 @@ static GLboolean WINAPI X11DRV_wglGetPixelFormatAttribivARB(HDC hdc, int iPixelF
piValues[i] = GL_FALSE;
continue;
case WGL_SWAP_METHOD_ARB:
/* For now return SWAP_EXCHANGE_ARB which is the best type of buffer switch available.
* Later on we can also use GLX_OML_swap_method on drivers which support this. At this
* point only ATI offers this.
*/
piValues[i] = WGL_SWAP_EXCHANGE_ARB;
break;
case WGL_PBUFFER_LARGEST_ARB:
curGLXAttr = GLX_LARGEST_PBUFFER;
break;

View File

@ -79,6 +79,10 @@
#define WGL_GENERIC_ACCELERATION_ARB 0x2026
#define WGL_FULL_ACCELERATION_ARB 0x2027
#define WGL_SWAP_EXCHANGE_ARB 0x2028
#define WGL_SWAP_COPY_ARB 0x2029
#define WGL_SWAP_UNDEFINED_ARB 0x202A
#define WGL_PBUFFER_WIDTH_ARB 0x2034
#define WGL_PBUFFER_HEIGHT_ARB 0x2035
#define WGL_PBUFFER_LOST_ARB 0x2036