[WINED3D 8/8] Make GetTexture read from the correct stateblock

Ivan Gyurdiev ivg231 at gmail.com
Mon Oct 2 19:22:25 CDT 2006


This fixes a failure in the textures test.

There's at least 5 other offenders that I see reading from the wrong 
stateblock, but they'll get their own test and patch.

-------------- next part --------------
>From f40c22821d4190cf3352de26127d1c82ee946bcf Mon Sep 17 00:00:00 2001
From: Ivan Gyurdiev <ivg2 at cornell.edu>
Date: Sun, 24 Sep 2006 02:11:26 -0400
Subject: [PATCH] Make GetTexture read from the correct stateblock.

This fixes a failure in the textures test.
---
 dlls/wined3d/device.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index c8c3b4e..f706b4c 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -5845,13 +5845,13 @@ static HRESULT WINAPI IWineD3DDeviceImpl
     /* Check for vertex shader textures */
 
     if (Stage == D3DDMAPSAMPLER)
-        *ppTexture = This->updateStateBlock->dmapTexture;
+        *ppTexture = This->stateBlock->dmapTexture;
 
     else if (Stage >= D3DVERTEXTEXTURESAMPLER0 && Stage <= D3DVERTEXTEXTURESAMPLER3)
-        *ppTexture = This->updateStateBlock->vertexTextures[Stage - D3DVERTEXTEXTURESAMPLER0];
+        *ppTexture = This->stateBlock->vertexTextures[Stage - D3DVERTEXTEXTURESAMPLER0];
 
     else if (Stage < GL_LIMITS(sampler_stages))
-        *ppTexture = This->updateStateBlock->textures[Stage];
+        *ppTexture = This->stateBlock->textures[Stage];
 
     else {
         TRACE("Attempt to access invalid texture rejected\n");
-- 
1.4.2.1



More information about the wine-patches mailing list