[PATCH 3/5] wined3d: Update shader constants on viewport changes.

Henri Verbeet hverbeet at codeweavers.com
Wed Apr 7 14:04:47 CDT 2010


Otherwise the vertex shader will see stale posFixup values.
---
 dlls/wined3d/state.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c
index fc6d265..5d6c19a 100644
--- a/dlls/wined3d/state.c
+++ b/dlls/wined3d/state.c
@@ -4682,6 +4682,8 @@ static void viewport_vertexpart(DWORD state, IWineD3DStateBlockImpl *stateblock,
     if(!isStateDirty(context, STATE_RENDER(WINED3DRS_POINTSCALEENABLE))) {
         state_pscale(STATE_RENDER(WINED3DRS_POINTSCALEENABLE), stateblock, context);
     }
+    if (!isStateDirty(context, STATE_VERTEXSHADERCONSTANT))
+        shaderconstant(STATE_VERTEXSHADERCONSTANT, stateblock, context);
 }
 
 static void light(DWORD state, IWineD3DStateBlockImpl *stateblock, struct wined3d_context *context)
-- 
1.6.4.4




More information about the wine-patches mailing list