summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar bunnei2018-07-02 23:48:52 -0400
committerGravatar GitHub2018-07-02 23:48:52 -0400
commite3ca561ea0aa2e38dd1bba6757c7170448579554 (patch)
tree7eeeda369d77431fc2f915d0265a47f308c0be46 /src
parentMerge pull request #611 from Subv/enabled_depth_test (diff)
parentgl_rasterizer: Only set cull mode and front face if enabled. (diff)
downloadyuzu-e3ca561ea0aa2e38dd1bba6757c7170448579554.tar.gz
yuzu-e3ca561ea0aa2e38dd1bba6757c7170448579554.tar.xz
yuzu-e3ca561ea0aa2e38dd1bba6757c7170448579554.zip
Merge pull request #612 from bunnei/fix-cull
gl_rasterizer: Only set cull mode and front face if enabled.
Diffstat (limited to 'src')
-rw-r--r--src/video_core/renderer_opengl/gl_rasterizer.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp
index 1ced31e84..dea88dfce 100644
--- a/src/video_core/renderer_opengl/gl_rasterizer.cpp
+++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp
@@ -718,8 +718,11 @@ void RasterizerOpenGL::SyncCullMode() {
718 const auto& regs = Core::System().GetInstance().GPU().Maxwell3D().regs; 718 const auto& regs = Core::System().GetInstance().GPU().Maxwell3D().regs;
719 719
720 state.cull.enabled = regs.cull.enabled != 0; 720 state.cull.enabled = regs.cull.enabled != 0;
721 state.cull.front_face = MaxwellToGL::FrontFace(regs.cull.front_face); 721
722 state.cull.mode = MaxwellToGL::CullFace(regs.cull.cull_face); 722 if (state.cull.enabled) {
723 state.cull.front_face = MaxwellToGL::FrontFace(regs.cull.front_face);
724 state.cull.mode = MaxwellToGL::CullFace(regs.cull.cull_face);
725 }
723} 726}
724 727
725void RasterizerOpenGL::SyncDepthScale() { 728void RasterizerOpenGL::SyncDepthScale() {