summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_state.cpp
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2019-12-26 05:28:17 +0100
committerReinUsesLisp <reinuseslisp@airmail.cc>2020-02-28 21:00:23 +0100
commit7c16b3551b5294d86a7dc8e0721c081bd88547ed (patch)
tree481af352889cd5c22166c215d755f93a297869ef /src/video_core/renderer_opengl/gl_state.cpp
parentgl_state: Remove color mask tracking (diff)
downloadyuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar.gz
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar.bz2
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar.lz
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar.xz
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.tar.zst
yuzu-7c16b3551b5294d86a7dc8e0721c081bd88547ed.zip
Diffstat (limited to 'src/video_core/renderer_opengl/gl_state.cpp')
-rw-r--r--src/video_core/renderer_opengl/gl_state.cpp35
1 files changed, 0 insertions, 35 deletions
diff --git a/src/video_core/renderer_opengl/gl_state.cpp b/src/video_core/renderer_opengl/gl_state.cpp
index bcacc5590..dcea16fd3 100644
--- a/src/video_core/renderer_opengl/gl_state.cpp
+++ b/src/video_core/renderer_opengl/gl_state.cpp
@@ -171,19 +171,6 @@ void OpenGLState::ApplyViewport() {
current.depth_range_far = updated.depth_range_far;
glDepthRangeIndexed(i, updated.depth_range_near, updated.depth_range_far);
}
-
- Enable(GL_SCISSOR_TEST, i, current.scissor.enabled, updated.scissor.enabled);
-
- if (current.scissor.x != updated.scissor.x || current.scissor.y != updated.scissor.y ||
- current.scissor.width != updated.scissor.width ||
- current.scissor.height != updated.scissor.height) {
- current.scissor.x = updated.scissor.x;
- current.scissor.y = updated.scissor.y;
- current.scissor.width = updated.scissor.width;
- current.scissor.height = updated.scissor.height;
- glScissorIndexed(i, updated.scissor.x, updated.scissor.y, updated.scissor.width,
- updated.scissor.height);
- }
}
}
@@ -306,28 +293,6 @@ void OpenGLState::Apply() {
ApplyRenderBuffer();
}
-void OpenGLState::EmulateViewportWithScissor() {
- auto& current = viewports[0];
- if (current.scissor.enabled) {
- const GLint left = std::max(current.x, current.scissor.x);
- const GLint right =
- std::max(current.x + current.width, current.scissor.x + current.scissor.width);
- const GLint bottom = std::max(current.y, current.scissor.y);
- const GLint top =
- std::max(current.y + current.height, current.scissor.y + current.scissor.height);
- current.scissor.x = std::max(left, 0);
- current.scissor.y = std::max(bottom, 0);
- current.scissor.width = std::max(right - left, 0);
- current.scissor.height = std::max(top - bottom, 0);
- } else {
- current.scissor.enabled = true;
- current.scissor.x = current.x;
- current.scissor.y = current.y;
- current.scissor.width = current.width;
- current.scissor.height = current.height;
- }
-}
-
OpenGLState& OpenGLState::UnbindTexture(GLuint handle) {
for (auto& texture : textures) {
if (texture == handle) {