diff options
author | bunnei <bunneidev@gmail.com> | 2018-11-22 06:51:01 +0100 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-11-22 06:51:01 +0100 |
commit | 0e6a608245700d1fe08292db96ed29f46b6cb9d6 (patch) | |
tree | f9910e656e86a7a19c6a74ca4a420a3b44f32f4d | |
parent | Merge pull request #1754 from ReinUsesLisp/zero-register (diff) | |
download | yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar.gz yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar.bz2 yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar.lz yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar.xz yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.tar.zst yuzu-0e6a608245700d1fe08292db96ed29f46b6cb9d6.zip |
-rw-r--r-- | src/video_core/engines/maxwell_3d.h | 7 | ||||
-rw-r--r-- | src/video_core/renderer_opengl/maxwell_to_gl.h | 5 |
2 files changed, 12 insertions, 0 deletions
diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h index 9e480dc39..eff6abd55 100644 --- a/src/video_core/engines/maxwell_3d.h +++ b/src/video_core/engines/maxwell_3d.h @@ -389,6 +389,13 @@ public: ReverseSubtract = 3, Min = 4, Max = 5, + + // These values are used by Nouveau and some games. + AddGL = 0x8006, + SubtractGL = 0x8007, + ReverseSubtractGL = 0x8008, + MinGL = 0x800a, + MaxGL = 0x800b }; enum class Factor : u32 { diff --git a/src/video_core/renderer_opengl/maxwell_to_gl.h b/src/video_core/renderer_opengl/maxwell_to_gl.h index 065b3929c..a8833c06e 100644 --- a/src/video_core/renderer_opengl/maxwell_to_gl.h +++ b/src/video_core/renderer_opengl/maxwell_to_gl.h @@ -218,14 +218,19 @@ inline GLenum DepthCompareFunc(Tegra::Texture::DepthCompareFunc func) { inline GLenum BlendEquation(Maxwell::Blend::Equation equation) { switch (equation) { case Maxwell::Blend::Equation::Add: + case Maxwell::Blend::Equation::AddGL: return GL_FUNC_ADD; case Maxwell::Blend::Equation::Subtract: + case Maxwell::Blend::Equation::SubtractGL: return GL_FUNC_SUBTRACT; case Maxwell::Blend::Equation::ReverseSubtract: + case Maxwell::Blend::Equation::ReverseSubtractGL: return GL_FUNC_REVERSE_SUBTRACT; case Maxwell::Blend::Equation::Min: + case Maxwell::Blend::Equation::MinGL: return GL_MIN; case Maxwell::Blend::Equation::Max: + case Maxwell::Blend::Equation::MaxGL: return GL_MAX; } LOG_ERROR(Render_OpenGL, "Unimplemented blend equation={}", static_cast<u32>(equation)); |