H. Verbeet : wined3d:
Mask texture stage state arguments with WINED3DTA_SELECTMASK when
comparing them .
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Jun 18 08:05:03 CDT 2007
Module: wine
Branch: master
Commit: b16dbf46da304f24163c21b072740e55fc34ea35
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b16dbf46da304f24163c21b072740e55fc34ea35
Author: H. Verbeet <hverbeet at gmail.com>
Date: Sun Jun 17 23:39:24 2007 +0200
wined3d: Mask texture stage state arguments with WINED3DTA_SELECTMASK when comparing them.
---
dlls/wined3d/utils.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c
index d592bc4..65bff5c 100644
--- a/dlls/wined3d/utils.c
+++ b/dlls/wined3d/utils.c
@@ -834,9 +834,12 @@ static BOOL is_invalid_op(IWineD3DDeviceImpl *This, int stage, WINED3DTEXTUREOP
if (op == WINED3DTOP_DISABLE) return FALSE;
if (This->stateBlock->textures[stage]) return FALSE;
- if (arg1 == WINED3DTA_TEXTURE && op != WINED3DTOP_SELECTARG2) return TRUE;
- if (arg2 == WINED3DTA_TEXTURE && op != WINED3DTOP_SELECTARG1) return TRUE;
- if (arg3 == WINED3DTA_TEXTURE && (op == WINED3DTOP_MULTIPLYADD || op == WINED3DTOP_LERP)) return TRUE;
+ if ((arg1 & WINED3DTA_SELECTMASK) == WINED3DTA_TEXTURE
+ && op != WINED3DTOP_SELECTARG2) return TRUE;
+ if ((arg2 & WINED3DTA_SELECTMASK) == WINED3DTA_TEXTURE
+ && op != WINED3DTOP_SELECTARG1) return TRUE;
+ if ((arg3 & WINED3DTA_SELECTMASK) == WINED3DTA_TEXTURE
+ && (op == WINED3DTOP_MULTIPLYADD || op == WINED3DTOP_LERP)) return TRUE;
return FALSE;
}
More information about the wine-cvs
mailing list