pixelShaderGen: also execute alpha test for always fail with late z test

This should fix issue 6493, but maybe no real issue as this rendering just do nothing
This commit is contained in:
degasus 2013-08-19 21:27:54 +02:00
parent 3a7802e771
commit 814c1c9572
1 changed files with 4 additions and 1 deletions

View File

@ -627,7 +627,10 @@ static inline void GeneratePixelShader(T& out, DSTALPHA_MODE dstAlphaMode, API_T
AlphaTest::TEST_RESULT Pretest = bpmem.alpha_test.TestResult();
uid_data.Pretest = Pretest;
if (Pretest == AlphaTest::UNDETERMINED)
// NOTE: Fragment may not be discarded if alpha test always fails and early depth test is enabled
// (in this case we need to write a depth value if depth test passes regardless of the alpha testing result)
if (Pretest == AlphaTest::UNDETERMINED || (Pretest == AlphaTest::FAIL && bpmem.UseLateDepthTest()))
WriteAlphaTest<T>(out, uid_data, ApiType, dstAlphaMode, per_pixel_depth);