fixup
This commit is contained in:
parent
3ec4a6d856
commit
5e6b72bea9
2 changed files with 10 additions and 10 deletions
|
@ -393,10 +393,10 @@ static void ProcessTriangleInternal(const Shader::OutputVertex& v0,
|
|||
for (u16 x = min_x + 8; x < max_x; x += 0x10) {
|
||||
|
||||
// Do not process the pixel if it's inside the scissor box and the scissor mode is set to Exclude
|
||||
if (regs.scissor_test.mode == Regs::ScissorMode::Exclude) {
|
||||
if (x >= scissor_x && x <= scissor_x + scissor_width &&
|
||||
y >= scissor_y && y <= scissor_y + scissor_height)
|
||||
continue;
|
||||
if (regs.scissor_test.mode == Regs::ScissorMode::Exclude &&
|
||||
x >= scissor_x && x <= scissor_x + scissor_width &&
|
||||
y >= scissor_y && y <= scissor_y + scissor_height) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// Calculate the barycentric coordinates w0, w1 and w2
|
||||
|
|
|
@ -346,6 +346,12 @@ uniform sampler2D tex[3];
|
|||
void main() {
|
||||
)";
|
||||
|
||||
// Do not do any sort of processing if it's obvious we're not going to pass the alpha test
|
||||
if (config.alpha_test_func == Regs::CompareFunc::Never) {
|
||||
out += "discard; }";
|
||||
return out;
|
||||
}
|
||||
|
||||
// Append the scissor test
|
||||
if (config.scissor_test_mode == Regs::ScissorMode::Include || config.scissor_test_mode == Regs::ScissorMode::Exclude) {
|
||||
out += "if (scissor_left <= scissor_right || scissor_top >= scissor_bottom) discard;\n";
|
||||
|
@ -356,12 +362,6 @@ void main() {
|
|||
out += "(gl_FragCoord.x >= scissor_right && gl_FragCoord.x <= scissor_left && gl_FragCoord.y >= scissor_top && gl_FragCoord.y <= scissor_bottom)) discard;\n";
|
||||
}
|
||||
|
||||
// Do not do any sort of processing if it's obvious we're not going to pass the alpha test
|
||||
if (config.alpha_test_func == Regs::CompareFunc::Never) {
|
||||
out += "discard; }";
|
||||
return out;
|
||||
}
|
||||
|
||||
out += "vec4 combiner_buffer = vec4(0.0);\n";
|
||||
out += "vec4 next_combiner_buffer = tev_combiner_buffer_color;\n";
|
||||
out += "vec4 last_tex_env_out = vec4(0.0);\n";
|
||||
|
|
Loading…
Reference in a new issue