From 22267831e02792cd9f15c00e18d783429be6e291 Mon Sep 17 00:00:00 2001 From: Sergey Lipskiy Date: Thu, 6 Sep 2018 22:35:48 +0700 Subject: [PATCH] Optimize ShaderN64DepthCompare a little bit. --- .../OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp b/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp index 0098bb28..2ebe24e4 100644 --- a/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp +++ b/src/Graphics/OpenGLContext/GLSL/glsl_CombinerProgramBuilder.cpp @@ -1947,11 +1947,13 @@ public: { if (config.frameBufferEmulation.N64DepthCompare != 0) { m_part = + "uniform lowp int uEnableDepth; \n" "uniform lowp int uDepthMode; \n" "uniform lowp int uEnableDepthUpdate; \n" "uniform mediump float uDeltaZ; \n" - "bool depth_compare(highp float curZ) \n" + "bool depth_compare(highp float curZ) \n" "{ \n" + " if (uEnableDepth == 0) return true; \n" ; if (_glinfo.imageTextures) { m_part +=