wined3d: Opengl 2.x compile fix.

This commit is contained in:
Roderick Colenbrander 2006-03-02 13:27:13 +01:00 committed by Alexandre Julliard
parent e96f03a1d7
commit f8ed06ea3d
2 changed files with 17 additions and 5 deletions

View File

@ -3767,8 +3767,12 @@ HRESULT WINAPI IWineD3DDeviceImpl_SetRenderState(IWineD3DDevice *iface, D3DRENDE
}
if(!This->stateBlock->renderState[WINED3DRS_TWOSIDEDSTENCILMODE]) {
glStencilOpSeparate(GL_BACK, stencilFail, depthFail, stencilPass);
checkGLcall("glStencilOpSeparate(GL_BACK,...)");
if(GL_EXTCALL(glStencilOpSeparate)) {
GL_EXTCALL(glStencilOpSeparate(GL_BACK, stencilFail, depthFail, stencilPass));
checkGLcall("glStencilOpSeparate(GL_BACK,...)");
} else {
WARN("Unsupported in local OpenGL implementation: glStencilOpSeparate\n");
}
} else {
glStencilOp(stencilFail, depthFail, stencilPass);
checkGLcall("glStencilOp(...)");
@ -3796,8 +3800,11 @@ HRESULT WINAPI IWineD3DDeviceImpl_SetRenderState(IWineD3DDevice *iface, D3DRENDE
}
This->stencilfunc = func;
if(!This->stateBlock->renderState[WINED3DRS_TWOSIDEDSTENCILMODE]) {
glStencilFuncSeparate(GL_BACK, func, ref, mask);
checkGLcall("glStencilFuncSeparate(GL_BACK,...)");
if(GL_EXTCALL(glStencilFuncSeparate)) {
GL_EXTCALL(glStencilFuncSeparate(GL_BACK, func, ref, mask));
checkGLcall("glStencilOpSeparate(GL_BACK,...)");
} else
WARN("Unsupported in local OpenGL implementation: glStencilFuncSeparate\n");
} else {
glStencilFunc(func, ref, mask);
checkGLcall("glStencilFunc(...)");

View File

@ -803,7 +803,9 @@ typedef void (APIENTRY * PGLFNBEGINOCCLUSIONQUERYNVPROC) (GLuint id);
typedef void (APIENTRY * PGLFNENDOCCLUSIONQUERYNVPROC) (void);
typedef void (APIENTRY * PGLFNGETOCCLUSIONQUERYIVNVPROC) (GLuint id, GLenum pname, GLint *params);
typedef void (APIENTRY * PGLFNGETOCCLUSIONQUERYUIVNVPROC) (GLuint id, GLenum pname, GLuint *params);
/* OpenGL 2.0 */
typedef void (APIENTRY * PGLFNSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
typedef void (APIENTRY * PGLFNSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask);
/****************************************************
* OpenGL Official Version
@ -1032,6 +1034,9 @@ typedef enum _GL_SupportedExt {
USE_GL_FUNC(PGLFNVERTEXATTRIBPOINTERARBPROC, glVertexAttribPointerARB); \
USE_GL_FUNC(PGLFNENABLEVERTEXATTRIBARRAYARBPROC, glEnableVertexAttribArrayARB); \
USE_GL_FUNC(PGLFNDISABLEVERTEXATTRIBARRAYARBPROC, glDisableVertexAttribArrayARB); \
/* OpenGL 2.0 */ \
USE_GL_FUNC(PGLFNSTENCILOPSEPARATEPROC, glStencilOpSeparate); \
USE_GL_FUNC(PGLFNSTENCILFUNCSEPARATEPROC, glStencilFuncSeparate); \
#define GLX_EXT_FUNCS_GEN \
/** GLX_VERSION_1_3 **/ \