diff --git a/Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h b/Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h index 7d309dee38..b81d051a0f 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h +++ b/Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h @@ -121,14 +121,4 @@ extern CGcontext g_cgcontext; extern CGprofile g_cgvProf, g_cgfProf; #endif -// XXX: Dual-source blending in OpenGL does not work correctly yet. To make it -// work, we may need to use glBindFragDataLocation. To use that, we need to -// use GLSL shaders across the whole pipeline. Yikes! -#define USE_DUAL_SOURCE_BLEND - -// Can't get defined on my system for some reason... -#ifndef GL_ONE_MINUS_SRC1_ALPHA -#define GL_ONE_MINUS_SRC1_ALPHA 0x88FB -#endif - #endif // _GLINIT_H_ diff --git a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp index 86452adebd..78b422eed2 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/Render.cpp @@ -938,11 +938,9 @@ void Renderer::SetBlendMode(bool forceUpdate) u32 changes = forceUpdate ? 0xFFFFFFFF : newval ^ s_blendMode; -#ifdef USE_DUAL_SOURCE_BLEND bool useDstAlpha = !g_ActiveConfig.bDstAlphaPass && bpmem.dstalpha.enable && bpmem.blendmode.alphaupdate && bpmem.zcontrol.pixel_format == PIXELFMT_RGBA6_Z24 && g_ActiveConfig.bUseGLSL; bool useDualSource = useDstAlpha; -#endif if (changes & 1) // blend enable change @@ -950,19 +948,14 @@ void Renderer::SetBlendMode(bool forceUpdate) if (changes & 4) { -#ifdef USE_DUAL_SOURCE_BLEND // subtract enable change GLenum equation = newval & 4 ? GL_FUNC_REVERSE_SUBTRACT : GL_FUNC_ADD; GLenum equationAlpha = useDualSource ? GL_FUNC_ADD : equation; glBlendEquationSeparate(equation, equationAlpha); -#else - glBlendEquation(newval & 4 ? GL_FUNC_REVERSE_SUBTRACT : GL_FUNC_ADD); -#endif } if (changes & 0x1F8) { -#ifdef USE_DUAL_SOURCE_BLEND GLenum srcFactor = glSrcFactors[(newval >> 3) & 7]; GLenum srcFactorAlpha = srcFactor; GLenum dstFactor = glDestFactors[(newval >> 6) & 7]; @@ -985,9 +978,6 @@ void Renderer::SetBlendMode(bool forceUpdate) // blend RGB change glBlendFuncSeparate(srcFactor, dstFactor, srcFactorAlpha, dstFactorAlpha); -#else - glBlendFunc(glSrcFactors[(newval >> 3) & 7], glDestFactors[(newval >> 6) & 7]); -#endif } s_blendMode = newval;