Christopher GAUTIER : wined3d: Disable GL_REGISTER_COMBINERS_NV (
if supported) in IWineD3DSurfaceImpl_BltOverride.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Oct 6 13:37:11 CDT 2006
Module: wine
Branch: master
Commit: 331679bcc984ca3f5dbcd09e23843f8f9bedc619
URL: http://source.winehq.org/git/wine.git/?a=commit;h=331679bcc984ca3f5dbcd09e23843f8f9bedc619
Author: Christopher GAUTIER <krys at via.ecp.fr>
Date: Thu Oct 5 09:45:23 2006 +0200
wined3d: Disable GL_REGISTER_COMBINERS_NV (if supported) in IWineD3DSurfaceImpl_BltOverride.
---
dlls/wined3d/surface.c | 14 +++++++++++++-
1 files changed, 13 insertions(+), 1 deletions(-)
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
index f78d651..f139840 100644
--- a/dlls/wined3d/surface.c
+++ b/dlls/wined3d/surface.c
@@ -2333,9 +2333,9 @@ static HRESULT IWineD3DSurfaceImpl_BltOv
DWORD oldCKey;
DDCOLORKEY oldBltCKey = {0,0};
GLint oldLight, oldFog, oldDepth, oldBlend, oldCull, oldAlpha;
+ GLint oldStencil, oldNVRegisterCombiners = 0;
GLint alphafunc;
GLclampf alpharef;
- GLint oldStencil;
RECT SourceRectangle;
GLint oldDraw;
@@ -2397,6 +2397,10 @@ static HRESULT IWineD3DSurfaceImpl_BltOv
oldAlpha = glIsEnabled(GL_ALPHA_TEST);
oldStencil = glIsEnabled(GL_STENCIL_TEST);
+ if (GL_SUPPORT(NV_REGISTER_COMBINERS)) {
+ oldNVRegisterCombiners = glIsEnabled(GL_REGISTER_COMBINERS_NV);
+ }
+
glGetIntegerv(GL_ALPHA_TEST_FUNC, &alphafunc);
checkGLcall("glGetFloatv GL_ALPHA_TEST_FUNC");
glGetFloatv(GL_ALPHA_TEST_REF, &alpharef);
@@ -2433,6 +2437,10 @@ static HRESULT IWineD3DSurfaceImpl_BltOv
checkGLcall("glDisable GL_CULL_FACE");
glDisable(GL_STENCIL_TEST);
checkGLcall("glDisable GL_STENCIL_TEST");
+ if (GL_SUPPORT(NV_REGISTER_COMBINERS)) {
+ glDisable(GL_REGISTER_COMBINERS_NV);
+ checkGLcall("glDisable GL_REGISTER_COMBINERS_NV");
+ }
/* Ok, we need 2d textures, but not 1D or 3D */
glDisable(GL_TEXTURE_1D);
@@ -2536,6 +2544,10 @@ static HRESULT IWineD3DSurfaceImpl_BltOv
glEnable(GL_ALPHA_TEST);
checkGLcall("glEnable GL_ALPHA_TEST");
}
+ if (GL_SUPPORT(NV_REGISTER_COMBINERS) && oldNVRegisterCombiners) {
+ glEnable(GL_REGISTER_COMBINERS_NV);
+ checkGLcall("glEnable GL_REGISTER_COMBINERS_NV");
+ }
glAlphaFunc(alphafunc, alpharef);
checkGLcall("glAlphaFunc\n");
More information about the wine-cvs
mailing list