Stefan Dösinger : wined3d: Remove the apply_pshader_fog state handler.

Alexandre Julliard julliard at winehq.org
Mon Jan 12 10:40:32 CST 2009


Module: wine
Branch: master
Commit: 061087811f14c708dcba87925bc2fbd2b4302afb
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=061087811f14c708dcba87925bc2fbd2b4302afb

Author: Stefan Dösinger <stefan at codeweavers.com>
Date:   Sun Dec 14 17:51:32 2008 +0100

wined3d: Remove the apply_pshader_fog state handler.

The fog doesn't depend on pixel shaders any longer(but still vice
versa), so we don't need this state any more.

---

 dlls/wined3d/state.c |   17 -----------------
 1 files changed, 0 insertions(+), 17 deletions(-)

diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c
index 60ab923..650141d 100644
--- a/dlls/wined3d/state.c
+++ b/dlls/wined3d/state.c
@@ -3370,21 +3370,6 @@ static void sampler(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DCont
     }
 }
 
-static void apply_pshader_fog(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContext *context) {
-    if (use_ps(stateblock))
-    {
-        if(!context->last_was_pshader) {
-            state_fog(state, stateblock, context);
-        }
-        context->last_was_pshader = TRUE;
-    } else {
-        if(context->last_was_pshader) {
-            state_fog(state, stateblock, context);
-        }
-        context->last_was_pshader = FALSE;
-    }
-}
-
 void apply_pixelshader(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DContext *context) {
     IWineD3DDeviceImpl *device = stateblock->wineD3DDevice;
     BOOL use_pshader = use_ps(stateblock);
@@ -5208,8 +5193,6 @@ const struct StateEntryTemplate ffp_vertexstate_template[] = {
     { STATE_RENDER(WINED3DRS_POINTSIZE_MAX),              { STATE_RENDER(WINED3DRS_POINTSIZE_MIN),              state_psizemin_arb  }, ARB_POINT_PARAMETERS            },
     { STATE_RENDER(WINED3DRS_POINTSIZE_MAX),              { STATE_RENDER(WINED3DRS_POINTSIZE_MIN),              state_psizemin_ext  }, EXT_POINT_PARAMETERS            },
     { STATE_RENDER(WINED3DRS_POINTSIZE_MAX),              { STATE_RENDER(WINED3DRS_POINTSIZE_MIN),              state_psizemin_w    }, 0                               },
-    /* pixel shaders need a different fog input */
-    { STATE_PIXELSHADER,                                  { STATE_PIXELSHADER,                                  apply_pshader_fog   }, 0                               },
     /* Samplers for NP2 texture matrix adjustions. They are not needed if GL_ARB_texture_non_power_of_two is supported,
      * so register a NULL state handler in that case to get the vertex part of sampler() skipped(VTF is handled in the misc states.
      * otherwise, register sampler_texmatrix, which takes care of updating the texture matrix




More information about the wine-cvs mailing list