diff options
author | bunnei <bunneidev@gmail.com> | 2016-03-06 17:16:21 +0100 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2016-03-06 17:16:21 +0100 |
commit | 6436d101b5d623aa7c5a854bf3b28fbefe2d5198 (patch) | |
tree | 7f3146a9a8062a7b29c11ab5c2499f81e9d2b1e6 /src/video_core/renderer_opengl | |
parent | Merge pull request #1463 from yuriks/non-app-region (diff) | |
parent | Pica: Write depth value even when depth test is disabled (diff) | |
download | yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar.gz yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar.bz2 yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar.lz yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar.xz yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.tar.zst yuzu-6436d101b5d623aa7c5a854bf3b28fbefe2d5198.zip |
Diffstat (limited to 'src/video_core/renderer_opengl')
-rw-r--r-- | src/video_core/renderer_opengl/gl_rasterizer.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 0f864b617..b3dc6aa19 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp @@ -887,8 +887,10 @@ void RasterizerOpenGL::SyncStencilTest() { void RasterizerOpenGL::SyncDepthTest() { const auto& regs = Pica::g_state.regs; - state.depth.test_enabled = (regs.output_merger.depth_test_enable == 1); - state.depth.test_func = PicaToGL::CompareFunc(regs.output_merger.depth_test_func); + state.depth.test_enabled = regs.output_merger.depth_test_enable == 1 || + regs.output_merger.depth_write_enable == 1; + state.depth.test_func = regs.output_merger.depth_test_enable == 1 ? + PicaToGL::CompareFunc(regs.output_merger.depth_test_func) : GL_ALWAYS; state.color_mask.red_enabled = regs.output_merger.red_enable; state.color_mask.green_enabled = regs.output_merger.green_enable; state.color_mask.blue_enabled = regs.output_merger.blue_enable; |