Stencil-to-alpha fragment tweak: Set alpha to 0 if we can't deduce the stencil value.

This fixes the weird glowing shadows in Wipeout.
This commit is contained in:
Henrik Rydgard 2013-12-04 19:55:09 +01:00
parent 50f67d631d
commit 41209eb936

View file

@ -453,7 +453,9 @@ void GenerateFragmentShader(char *buffer) {
break; break;
case STENCIL_VALUE_UNKNOWN: case STENCIL_VALUE_UNKNOWN:
// Do nothing. // Maybe we should even mask away alpha using glColorMask and not change it at all? We do get here
// if the stencil mode is KEEP for example.
WRITE(p, " gl_FragColor.a = 0.0;\n");
break; break;
} }
} }