From f4d8af2f0d677aabc78720dd0b2b87ae27f8bf27 Mon Sep 17 00:00:00 2001 From: lightningterror <18107717+lightningterror@users.noreply.github.com> Date: Thu, 26 Jun 2025 09:07:21 +0200 Subject: [PATCH] GS/GL: Don't re enable blend after SetupDATE. Redundant calls, blending will be enabled if needed. --- pcsx2/GS/Renderers/OpenGL/GSDeviceOGL.cpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/pcsx2/GS/Renderers/OpenGL/GSDeviceOGL.cpp b/pcsx2/GS/Renderers/OpenGL/GSDeviceOGL.cpp index 74b86a9f1b..c8c1e52978 100644 --- a/pcsx2/GS/Renderers/OpenGL/GSDeviceOGL.cpp +++ b/pcsx2/GS/Renderers/OpenGL/GSDeviceOGL.cpp @@ -1911,7 +1911,7 @@ void GSDeviceOGL::SetupDATE(GSTexture* rt, GSTexture* ds, const GSVertexPT1* ver OMSetRenderTargets(nullptr, ds, &GLState::scissor); { - const GLint clear_color = 0; + constexpr GLint clear_color = 0; glClearBufferiv(GL_STENCIL, 0, &clear_color); } m_convert.ps[SetDATMShader(datm)].Bind(); @@ -1919,10 +1919,8 @@ void GSDeviceOGL::SetupDATE(GSTexture* rt, GSTexture* ds, const GSVertexPT1* ver // om OMSetDepthStencilState(m_date.dss); - if (GLState::blend) - { - glDisable(GL_BLEND); - } + OMSetBlendState(false); + OMSetColorMaskState(); // ia @@ -1930,18 +1928,12 @@ void GSDeviceOGL::SetupDATE(GSTexture* rt, GSTexture* ds, const GSVertexPT1* ver IASetVertexBuffer(vertices, 4); IASetPrimitiveTopology(GL_TRIANGLE_STRIP); - // Texture PSSetShaderResource(0, rt); PSSetSamplerState(m_convert.pt); DrawPrimitive(); - - if (GLState::blend) - { - glEnable(GL_BLEND); - } } void GSDeviceOGL::IASetVAO(GLuint vao)