WineD3D don't use OpenGL 2.0

Roderick Colenbrander thunderbird2k at gmx.net
Sun Mar 19 16:38:23 CST 2006


Hi,

At the moment wined3d uses two OpenGL 2.0 functions namely
StencilFuncSeparate and StencilOpSeparate. We dynamicly load ~90 OpenGL 2.0
using glXGetProcAddress and we check the function pointers to see if the
function is 'available'. This resulted in crashes on systems using Mesa
because Mesa returned non-NULL values for functions for which it didn't have
implementations. According to the GLX specs this is perfectly legal.

Another option is to check if the OpenGL version is 2.0 and only then load
the function and set the function pointers to NULL in other cases. This
isn't possible either because not all OpenGL functions have to be supported
when the version is 2.0. This useally happens when you are using remote X.

In the end the best option is to don't use the OpenGL 2.0 functions yet as
the needed functionality is also available through OpenGL 1.x extensions
(this code is already in wine). These extensions stay around for backwards
compatibility so there's no reason to use the OpenGL 2.0 calls at the
moment.

This patch disables the OpenGL 2.0 functions I mentioned above. Second we
don't use any OpenGL 2.0 functionality yet while we preload all new calls.
This patches also moves the opengl 2.0 functions defines out of the list of
opengl extensions in wine_gl.h. This saves us the loading of 90 functions
which we don't need yet.

Regards,
Roderick Colenbrander

-- 
Bis zu 70% Ihrer Onlinekosten sparen: GMX SmartSurfer!
Kostenlos downloaden: http://www.gmx.net/de/go/smartsurfer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: opengl2.patch
Type: text/x-patch
Size: 4222 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20060319/8dffbc59/opengl2-0001.patch


More information about the wine-patches mailing list