Module: wine Branch: refs/heads/master Commit: 9d4960bfcb927644503861ae627cb79b9aceb81c URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=9d4960bfcb927644503861ae...
Author: Ivan Gyurdiev ivg2@cornell.edu Date: Tue May 9 18:09:12 2006 -0400
wined3d: Clean up some dead code.
---
dlls/wined3d/pixelshader.c | 27 ++++++++++----------------- dlls/wined3d/vertexshader.c | 17 ++++++++--------- 2 files changed, 18 insertions(+), 26 deletions(-)
diff --git a/dlls/wined3d/pixelshader.c b/dlls/wined3d/pixelshader.c index 417546c..e00eebf 100644 --- a/dlls/wined3d/pixelshader.c +++ b/dlls/wined3d/pixelshader.c @@ -1169,12 +1169,8 @@ inline static VOID IWineD3DPixelShaderIm IWineD3DPixelShaderImpl *This = (IWineD3DPixelShaderImpl *)iface; const DWORD *pToken = pFunction; const SHADER_OPCODE *curOpcode = NULL; - const DWORD *pInstr; DWORD i; char tmpLine[255]; -#if 0 /* TODO: loop register (just another address register ) */ - BOOL hasLoops = FALSE; -#endif SHADER_BUFFER buffer;
int row = 0; /* not sure, something to do with macros? */ @@ -1261,21 +1257,23 @@ #endif pToken += comment_len; continue; } -#if 0 /* Not sure what these are here for, they're not required for vshaders */ - code = *pToken; -#endif - pInstr = pToken; + + /* Read opcode */ curOpcode = shader_get_opcode((IWineD3DBaseShader*) This, *pToken); ++pToken; + + /* Unknown opcode and its parameters */ if (NULL == curOpcode) { - /* unknown current opcode ... (shouldn't be any!) */ while (*pToken & 0x80000000) { /* TODO: Think of a sensible name for 0x80000000 */ FIXME("unrecognized opcode: %08lx\n", *pToken); ++pToken; } + + /* Unhandled opcode */ } else if (GLNAME_REQUIRE_GLSL == curOpcode->glname) { - /* if the token isn't supported by this cross compiler then skip it and its parameters */ - FIXME("Token %s requires greater functionality than Fragment_Progarm_ARB supports\n", curOpcode->name); + + FIXME("Token %s requires greater functionality than " + "Fragment_Progarm_ARB supports\n", curOpcode->name); pToken += curOpcode->num_params;
} else if (D3DSIO_DEF == curOpcode->opcode) { @@ -1420,13 +1418,8 @@ #endif break;
default: - if (curOpcode->glname == GLNAME_REQUIRE_GLSL) { - FIXME("Opcode %s requires Gl Shader languange 1.0\n", curOpcode->name); - } else { - FIXME("Can't handle opcode %s in hwShader\n", curOpcode->name); - } + FIXME("Can't handle opcode %s in hwShader\n", curOpcode->name); pToken += curOpcode->num_params; - continue; } } } diff --git a/dlls/wined3d/vertexshader.c b/dlls/wined3d/vertexshader.c index 3e50eed..770242c 100644 --- a/dlls/wined3d/vertexshader.c +++ b/dlls/wined3d/vertexshader.c @@ -1190,18 +1190,22 @@ #endif continue; }
+ /* Read opcode */ curOpcode = shader_get_opcode((IWineD3DBaseShader*) This, *pToken); ++pToken; + + /* Unknown opcode and its parameters */ if (NULL == curOpcode) { - /* unknown current opcode ... (shouldn't be any!) */ while (*pToken & 0x80000000) { FIXME("unrecognized opcode: %08lx\n", *pToken); ++pToken; } + + /* Unhandled opcode */ } else if (GLNAME_REQUIRE_GLSL == curOpcode->glname) { - /* if the token isn't supported by this cross compiler then skip it and its parameters */
- FIXME("Token %s requires greater functionality than Vertex_Progarm_ARB supports\n", curOpcode->name); + FIXME("Token %s requires greater functionality than " + "Vertex_Program_ARB supports\n", curOpcode->name); pToken += curOpcode->num_params;
} else if (D3DSIO_DEF == curOpcode->opcode) { @@ -1336,12 +1340,7 @@ #endif break;
default: - if (curOpcode->glname == GLNAME_REQUIRE_GLSL) { - FIXME("Opcode %s requires Gl Shader languange 1.0\n", curOpcode->name); - } else { - FIXME("Can't handle opcode %s in hwShader\n", curOpcode->name); - } - + FIXME("Can't handle opcode %s in hwShader\n", curOpcode->name); pToken += curOpcode->num_params; } }