rasterize: fix an interaction between polyids and shadows resulting in failure to render shadows sometimes
This commit is contained in:
parent
2fbf9e8d94
commit
0e2532cc85
|
@ -604,16 +604,19 @@ static void triangle_from_devmaster()
|
||||||
destFragment.polyid.opaque = polyAttr.polyid;
|
destFragment.polyid.opaque = polyAttr.polyid;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
//interesting that we have to check for mode 3 here. not very straightforward, but then nothing about the shadows are
|
||||||
|
//this was the result of testing trauma center, SPP area menu, and SM64 with yoshi's red feet behind translucent trees
|
||||||
|
//as well as the intermittent bug in ff4 where your shadow only appears under other shadows
|
||||||
|
if(shader.mode != 3)
|
||||||
{
|
{
|
||||||
//dont overwrite pixels on translucent polys with the same polyids
|
//dont overwrite pixels on translucent polys with the same polyids
|
||||||
if(destFragment.polyid.translucent == polyAttr.polyid)
|
if(destFragment.polyid.translucent == polyAttr.polyid)
|
||||||
goto rejected_fragment;
|
goto rejected_fragment;
|
||||||
|
|
||||||
//this is an interesting item. not very straightforward, but then nothing about the shadows are
|
|
||||||
//this was the result of testing trauma center, SPP area menu, and SM64 with yoshi's red feet behind translucent trees
|
|
||||||
if(shader.mode != 3)
|
|
||||||
destFragment.polyid.translucent = polyAttr.polyid;
|
destFragment.polyid.translucent = polyAttr.polyid;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//alpha blending and write color
|
//alpha blending and write color
|
||||||
alphaBlend(destFragment.color, shaderOutput.color);
|
alphaBlend(destFragment.color, shaderOutput.color);
|
||||||
|
|
Loading…
Reference in New Issue