summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_state.cpp
diff options
context:
space:
mode:
authorJannik Vogel <email@jannikvogel.de>2016-05-12 22:57:15 +0200
committerJannik Vogel <email@jannikvogel.de>2016-05-12 22:57:40 +0200
commit5864cb7e00d241473b43f8895449f8cebb9e7ec5 (patch)
tree64decd59c20ccb7f8c3326758fabe2552f469827 /src/video_core/renderer_opengl/gl_state.cpp
parentMerge pull request #1690 from JayFoxRox/tex-type-3 (diff)
downloadyuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar.gz
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar.bz2
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar.lz
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar.xz
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.tar.zst
yuzu-5864cb7e00d241473b43f8895449f8cebb9e7ec5.zip
Diffstat (limited to 'src/video_core/renderer_opengl/gl_state.cpp')
-rw-r--r--src/video_core/renderer_opengl/gl_state.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_state.cpp b/src/video_core/renderer_opengl/gl_state.cpp
index 02cd9f417..fa141fc9a 100644
--- a/src/video_core/renderer_opengl/gl_state.cpp
+++ b/src/video_core/renderer_opengl/gl_state.cpp
@@ -36,6 +36,8 @@ OpenGLState::OpenGLState() {
stencil.action_stencil_fail = GL_KEEP;
blend.enabled = false;
+ blend.rgb_equation = GL_FUNC_ADD;
+ blend.a_equation = GL_FUNC_ADD;
blend.src_rgb_func = GL_ONE;
blend.dst_rgb_func = GL_ZERO;
blend.src_a_func = GL_ONE;
@@ -165,6 +167,11 @@ void OpenGLState::Apply() const {
blend.src_a_func, blend.dst_a_func);
}
+ if (blend.rgb_equation != cur_state.blend.rgb_equation ||
+ blend.a_equation != cur_state.blend.a_equation) {
+ glBlendEquationSeparate(blend.rgb_equation, blend.a_equation);
+ }
+
if (logic_op != cur_state.logic_op) {
glLogicOp(logic_op);
}