From c2b3fc13eb030536c16c365f4c062a953aa3abee Mon Sep 17 00:00:00 2001 From: Sergey Lipskiy Date: Wed, 1 Feb 2017 14:51:22 +0700 Subject: [PATCH] Disagle hw lighting for Rects. --- .../OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp b/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp index 49cb8eab..f0db56fd 100644 --- a/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp +++ b/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp @@ -1760,8 +1760,10 @@ graphics::CombinerProgram * CombinerProgramBuilder::buildCombinerProgram(Combine const bool bUseLod = combinerInputs.usesLOD(); const bool bUseTextures = combinerInputs.usesTexture(); - const bool bUseHWLight = - config.generalEmulation.enableHWLighting != 0 && GBI.isHWLSupported() && combinerInputs.usesShadeColor(); + const bool bUseHWLight = g_cycleType <= G_CYC_2CYCLE && // Rects not use lighting + config.generalEmulation.enableHWLighting != 0 && + GBI.isHWLSupported() && + combinerInputs.usesShadeColor(); if (bUseHWLight) combinerInputs.addInput(G_GCI_HW_LIGHT);