From 1f2a9e2c31fe17489b25b6427ac008273648ec25 Mon Sep 17 00:00:00 2001 From: Oliver Stieber Date: Sat, 29 Oct 2005 10:30:36 +0000 Subject: [PATCH] Move the softwareVertexProcessing flag from the stateblock to the device because its state shouldn't be recorded in a stateblock. --- dlls/wined3d/device.c | 4 ++-- dlls/wined3d/stateblock.c | 2 -- dlls/wined3d/wined3d_private.h | 6 ++++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index c076f6ae683..549399687e2 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -5008,7 +5008,7 @@ HRESULT WINAPI IWineD3DDeviceImpl_SetSoftwareVertexProcessing(IWineD3DDevice * showFixmes = FALSE; } - This->updateStateBlock->softwareVertexProcessing = bSoftware; + This->softwareVertexProcessing = bSoftware; return D3D_OK; } @@ -5020,7 +5020,7 @@ BOOL WINAPI IWineD3DDeviceImpl_GetSoftwareVertexProcessing(IWineD3DDevice * FIXME("(%p) : stub\n", This); showFixmes = FALSE; } - return This->updateStateBlock->softwareVertexProcessing; + return This->softwareVertexProcessing; } diff --git a/dlls/wined3d/stateblock.c b/dlls/wined3d/stateblock.c index c591f68a14e..2c4bd18505d 100644 --- a/dlls/wined3d/stateblock.c +++ b/dlls/wined3d/stateblock.c @@ -432,8 +432,6 @@ should really perform a delta so that only the changes get updated*/ IWineD3DDevice_SetVertexDeclaration(pDevice, This->vertexDecl); } - IWineD3DDevice_SetSoftwareVertexProcessing(pDevice, This->softwareVertexProcessing); - /* Others + Render & Texture */ if (/*TODO: 'magic' statetype, replace with BOOL This->blockType == D3DSBT_RECORDED || */ This->blockType == WINED3DSBT_ALL || This->blockType == WINED3DSBT_INIT) { for (i = 1; i <= HIGHEST_TRANSFORMSTATE; i++) { diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 16316166e10..65c59f50ae2 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -549,6 +549,10 @@ typedef struct IWineD3DDeviceImpl /* A flag to check if endscene has been called before changing the render tartet */ BOOL sceneEnded; + + /* process vertex shaders using software or hardware */ + BOOL softwareVertexProcessing; + } IWineD3DDeviceImpl; extern const IWineD3DDeviceVtbl IWineD3DDevice_Vtbl; @@ -912,8 +916,6 @@ struct IWineD3DStateBlockImpl float vertexShaderConstantF[MAX_VSHADER_CONSTANTS * 4]; WINESHADERCNST vertexShaderConstantT[MAX_VSHADER_CONSTANTS]; /* TODO: Think about changing this to a char to possibly save a little memory */ - BOOL softwareVertexProcessing; - /* Stream Source */ BOOL streamIsUP; UINT streamStride[MAX_STREAMS];