diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2019-12-29 02:12:12 +0100 |
---|---|---|
committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2020-02-28 21:56:41 +0100 |
commit | 7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1 (patch) | |
tree | a18e0a878c025c613b7dcf6f23db83011afda92e /src/video_core/renderer_opengl/renderer_opengl.cpp | |
parent | renderer_opengl: Reintroduce dirty flags for render targets (diff) | |
download | yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar.gz yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar.bz2 yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar.lz yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar.xz yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.tar.zst yuzu-7f52efdf61d16d6eaa7eea2500ceb28d9f1041e1.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/video_core/renderer_opengl/renderer_opengl.cpp b/src/video_core/renderer_opengl/renderer_opengl.cpp index 36c634e0d..73d2d9027 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.cpp +++ b/src/video_core/renderer_opengl/renderer_opengl.cpp @@ -576,6 +576,7 @@ void RendererOpenGL::DrawScreen(const Layout::FramebufferLayout& layout) { glNamedBufferSubData(vertex_buffer.handle, 0, sizeof(vertices), std::data(vertices)); // TODO: Signal state tracker about these changes + state_tracker.NotifyViewport0(); state_tracker.NotifyFramebuffer(); program_manager.UseVertexShader(vertex_program.handle); @@ -601,7 +602,9 @@ void RendererOpenGL::DrawScreen(const Layout::FramebufferLayout& layout) { glFrontFace(GL_CW); glColorMaski(0, GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); glClipControl(GL_LOWER_LEFT, GL_ZERO_TO_ONE); - glViewport(0, 0, layout.width, layout.height); + glViewportIndexedf(0, 0.0f, 0.0f, static_cast<GLfloat>(layout.width), + static_cast<GLfloat>(layout.height)); + glDepthRangeIndexed(0, 0.0, 0.0); glVertexAttribFormat(PositionLocation, 2, GL_FLOAT, GL_FALSE, offsetof(ScreenRectVertex, position)); |