summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_shader_gen.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/video_core/renderer_opengl/gl_shader_gen.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_gen.cpp b/src/video_core/renderer_opengl/gl_shader_gen.cpp
index 1808ee0a9..8f278722d 100644
--- a/src/video_core/renderer_opengl/gl_shader_gen.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_gen.cpp
@@ -645,11 +645,10 @@ vec4 secondary_fragment_color = vec4(0.0);
// Negate the condition if we have to keep only the pixels outside the scissor box
if (state.scissor_test_mode == Regs::ScissorMode::Include)
out += "!";
- // x2,y2 have +1 added to cover the entire pixel area
- out += "(gl_FragCoord.x >= scissor_x1 * framebuffer_scale.x && "
- "gl_FragCoord.y >= scissor_y1 * framebuffer_scale.y && "
- "gl_FragCoord.x < (scissor_x2 + 1) * framebuffer_scale.x && "
- "gl_FragCoord.y < (scissor_y2 + 1) * framebuffer_scale.y)) discard;\n";
+ out += "(gl_FragCoord.x >= scissor_x1 && "
+ "gl_FragCoord.y >= scissor_y1 && "
+ "gl_FragCoord.x < scissor_x2 && "
+ "gl_FragCoord.y < scissor_y2)) discard;\n";
}
out += "float z_over_w = 1.0 - gl_FragCoord.z * 2.0;\n";