Merge pull request #16066 from unknownbrackets/softgpu-fastrect

softgpu: Narrow blend check for fast path further
This commit is contained in:
Henrik Rydgård authored and GitHub committed 2022-09-21 10:01:04 +02:00
commit 95ea0450fc
1 file changed
+4 -1
+4 -1
View File
@@ -93,7 +93,10 @@ static inline bool AlphaTestIsNeedless(const PixelFuncID &pixelID) {
case GE_COMP_NOTEQUAL:
case GE_COMP_GREATER:
case GE_COMP_GEQUAL:
return pixelID.alphaBlend && pixelID.alphaTestRef == 0 && !pixelID.hasAlphaTestMask;
if (pixelID.alphaTestRef != 0 || pixelID.hasAlphaTestMask)
return false;
// DrawSinglePixel5551 assumes it can take the src color directly if full alpha.
return pixelID.alphaBlend && pixelID.AlphaBlendSrc() == PixelBlendFactor::SRCALPHA && pixelID.AlphaBlendDst() == PixelBlendFactor::INVSRCALPHA;
}
return false;