Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
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
  • Loading branch information
degasus committed Aug 19, 2013
1 parent 3a7802e commit 814c1c9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Source/Core/VideoCommon/Src/PixelShaderGen.cpp
Expand Up @@ -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);


Expand Down

0 comments on commit 814c1c9

Please sign in to comment.