renderergl2: reimplement greyscale as backend post after all 2D+3D draws

Fixes #654 - HUD/UI previously bypassed greyscale.
r_greyscale now supports partial desaturation [0-1].
Removed unused legacy logic from tr_shade.c
This commit is contained in:
Lojjik Braughler authored and Tim Angus committed 2025-11-11 12:21:15 +00:00
1 parent 7bd2c17f9d
commit 453705553b
9 files changed
+166 -111

No files matched your search

+2 -2
View File
@@ -592,7 +592,7 @@ void FBO_BlitFromTexture(struct image_s *src, vec4_t inSrcTexCorners, vec2_t inS
FBO_Bind(oldFbo);
}
void FBO_Blit(FBO_t *src, ivec4_t inSrcBox, vec2_t srcTexScale, FBO_t *dst, ivec4_t dstBox, struct shaderProgram_s *shaderProgram, vec4_t color, int blend)
void FBO_Blit(const FBO_t *src, ivec4_t inSrcBox, vec2_t srcTexScale, FBO_t *dst, ivec4_t dstBox, struct shaderProgram_s *shaderProgram, vec4_t color, int blend)
{
vec4_t srcTexCorners;
@@ -617,7 +617,7 @@ void FBO_Blit(FBO_t *src, ivec4_t inSrcBox, vec2_t srcTexScale, FBO_t *dst, ivec
FBO_BlitFromTexture(src->colorImage[0], srcTexCorners, srcTexScale, dst, dstBox, shaderProgram, color, blend | GLS_DEPTHTEST_DISABLE);
}
void FBO_FastBlit(FBO_t *src, ivec4_t srcBox, FBO_t *dst, ivec4_t dstBox, int buffers, int filter)
void FBO_FastBlit(const FBO_t *src, ivec4_t srcBox, FBO_t *dst, ivec4_t dstBox, int buffers, int filter)
{
ivec4_t srcBoxFinal, dstBoxFinal;
GLuint srcFb, dstFb;