Actually have Dual Source blending work for people. Forgot about this change.
This commit is contained in:
parent
a304af75fd
commit
a5257c1a0a
|
@ -124,6 +124,11 @@ extern CGprofile g_cgvProf, g_cgfProf;
|
||||||
// XXX: Dual-source blending in OpenGL does not work correctly yet. To make it
|
// 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
|
// work, we may need to use glBindFragDataLocation. To use that, we need to
|
||||||
// use GLSL shaders across the whole pipeline. Yikes!
|
// use GLSL shaders across the whole pipeline. Yikes!
|
||||||
//#define USE_DUAL_SOURCE_BLEND
|
#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_
|
#endif // _GLINIT_H_
|
||||||
|
|
|
@ -937,8 +937,8 @@ void Renderer::SetBlendMode(bool forceUpdate)
|
||||||
|
|
||||||
#ifdef USE_DUAL_SOURCE_BLEND
|
#ifdef USE_DUAL_SOURCE_BLEND
|
||||||
bool useDstAlpha = !g_ActiveConfig.bDstAlphaPass && bpmem.dstalpha.enable && bpmem.blendmode.alphaupdate
|
bool useDstAlpha = !g_ActiveConfig.bDstAlphaPass && bpmem.dstalpha.enable && bpmem.blendmode.alphaupdate
|
||||||
&& bpmem.zcontrol.pixel_format == PIXELFMT_RGBA6_Z24;
|
&& bpmem.zcontrol.pixel_format == PIXELFMT_RGBA6_Z24 && g_ActiveConfig.bUseGLSL;
|
||||||
bool useDualSource = useDstAlpha && GLEW_ARB_blend_func_extended;
|
bool useDualSource = useDstAlpha;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (changes & 1)
|
if (changes & 1)
|
||||||
|
|
Loading…
Reference in New Issue