mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-15 05:47:56 -07:00
ShaderGen: remove nonsense for() if() {}
This commit is contained in:
parent
72c1e143f3
commit
f62579761c
@ -318,9 +318,8 @@ static inline void GeneratePixelShader(T& out, DSTALPHA_MODE dstAlphaMode, API_T
|
|||||||
// Let's set up attributes
|
// Let's set up attributes
|
||||||
if (xfregs.numTexGen.numTexGens < 7)
|
if (xfregs.numTexGen.numTexGens < 7)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < 8; ++i)
|
for (int i = 0; i < xfregs.numTexGen.numTexGens; ++i)
|
||||||
if(i < xfregs.numTexGen.numTexGens)
|
out.Write("VARYIN float3 uv%d_2;\n", i);
|
||||||
out.Write("VARYIN float3 uv%d_2;\n", i);
|
|
||||||
out.Write("VARYIN float4 clipPos_2;\n");
|
out.Write("VARYIN float4 clipPos_2;\n");
|
||||||
if (g_ActiveConfig.bEnablePixelLighting && g_ActiveConfig.backend_info.bSupportsPixelLighting)
|
if (g_ActiveConfig.bEnablePixelLighting && g_ActiveConfig.backend_info.bSupportsPixelLighting)
|
||||||
{
|
{
|
||||||
|
@ -483,9 +483,8 @@ static inline void GenerateVertexShader(T& out, u32 components, API_TYPE api_typ
|
|||||||
|
|
||||||
if (xfregs.numTexGen.numTexGens < 7)
|
if (xfregs.numTexGen.numTexGens < 7)
|
||||||
{
|
{
|
||||||
for (unsigned int i = 0; i < 8; ++i)
|
for (unsigned int i = 0; i < xfregs.numTexGen.numTexGens; ++i)
|
||||||
if(i < xfregs.numTexGen.numTexGens)
|
out.Write(" uv%d_2.xyz = o.tex%d;\n", i, i);
|
||||||
out.Write(" uv%d_2.xyz = o.tex%d;\n", i, i);
|
|
||||||
out.Write(" clipPos_2 = o.clipPos;\n");
|
out.Write(" clipPos_2 = o.clipPos;\n");
|
||||||
if(g_ActiveConfig.bEnablePixelLighting && g_ActiveConfig.backend_info.bSupportsPixelLighting)
|
if(g_ActiveConfig.bEnablePixelLighting && g_ActiveConfig.backend_info.bSupportsPixelLighting)
|
||||||
out.Write(" Normal_2 = o.Normal;\n");
|
out.Write(" Normal_2 = o.Normal;\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user