From 54ed45f531928553e38519c4a858b9ad7b17ab2b Mon Sep 17 00:00:00 2001 From: Alug Date: Wed, 20 Dec 2023 17:38:20 +0100 Subject: [PATCH] remove pal postprocess shader MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit it never worked, and isnt the right one to do things anyways the normal GLSL_PALETTE_FRAGMENT_SHADER already does a good job as a postprocess shader, and works similar to srb2´s newer paletterenderer branch --- src/hardware/hw_main.c | 4 +--- src/hardware/r_opengl/r_opengl.c | 11 +---------- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/src/hardware/hw_main.c b/src/hardware/hw_main.c index 0c576b051..f0fab7fe5 100644 --- a/src/hardware/hw_main.c +++ b/src/hardware/hw_main.c @@ -892,7 +892,7 @@ void HWR_RenderPlane(subsector_t *subsector, extrasubsector_t *xsub, boolean isc if (PolyFlags & PF_Fog) HWD.pfnSetShader(6); // fog shader else if (PolyFlags & PF_Ripple) - HWD.pfnSetShader(HWR_ShouldUsePaletteRendering() ? 12 : 5); // water shader + HWD.pfnSetShader(HWR_ShouldUsePaletteRendering() ? 11 : 5); // water shader else HWD.pfnSetShader(HWR_ShouldUsePaletteRendering() ? 9 : 1); // floor shader @@ -6838,8 +6838,6 @@ void HWR_MakeScreenFinalTexture(void) void HWR_DrawScreenFinalTexture(int width, int height) { - if (HWR_ShouldUsePaletteRendering()) - HWD.pfnSetShader(11); //post processing HWD.pfnDrawScreenFinalTexture(width, height); } diff --git a/src/hardware/r_opengl/r_opengl.c b/src/hardware/r_opengl/r_opengl.c index 6c478a047..cf10c059f 100644 --- a/src/hardware/r_opengl/r_opengl.c +++ b/src/hardware/r_opengl/r_opengl.c @@ -812,11 +812,6 @@ static float shader_leveltime = 0; GLSL_SOFTWARE_PAL_MAIN \ "\0" -#define GLSL_SOFTWARE_PAL_FRAGMENT_SHADER_POSTPROCESS \ - GLSL_SOFTWARE_PAL_UNIFORMS \ - GLSL_SOFTWARE_PAL_MAIN \ - "\0" - // // Water surface shader // @@ -955,7 +950,7 @@ static const char *fragment_shaders[] = { "void main(void) {\n" "gl_FragColor = texture2D(tex, gl_TexCoord[0].st);\n" "}\0", - + // Palette fragment shader GLSL_PALETTE_FRAGMENT_SHADER, @@ -965,9 +960,6 @@ static const char *fragment_shaders[] = { // Palette wall fudge shader GLSL_SOFTWARE_PAL_FRAGMENT_SHADER_WALLS, - // Palette postprocess shader - GLSL_SOFTWARE_PAL_FRAGMENT_SHADER_POSTPROCESS, - // Palette water shader GLSL_PALETTE_WATER_FRAGMENT_SHADER, @@ -1021,7 +1013,6 @@ static const char *vertex_shaders[] = { GLSL_DEFAULT_VERTEX_SHADER, GLSL_DEFAULT_VERTEX_SHADER, GLSL_DEFAULT_VERTEX_SHADER, - GLSL_DEFAULT_VERTEX_SHADER, NULL, };