From d57896594c05a5b490fa2f8903fb5c3bb025d77f Mon Sep 17 00:00:00 2001 From: havoc Date: Sun, 16 Apr 2006 09:30:21 +0000 Subject: [PATCH] fix bug in glsl surface shader setup code which was breaking fog git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6293 d7cf8633-e32d-0410-b094-e92efae38249 --- gl_rmain.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gl_rmain.c b/gl_rmain.c index 44bf341a..a81e4305 100644 --- a/gl_rmain.c +++ b/gl_rmain.c @@ -953,11 +953,11 @@ void R_SetupSurfaceShader(const entity_render_t *ent, const texture_t *texture, if (r_glsl_permutation->loc_Texture_Color >= 0) R_Mesh_TexBind(1, R_GetTexture(texture->basetexture)); if (r_glsl_permutation->loc_Texture_Gloss >= 0) R_Mesh_TexBind(2, R_GetTexture(texture->glosstexture)); //if (r_glsl_permutation->loc_Texture_Cube >= 0 && permutation & SHADERPERMUTATION_MODE_LIGHTSOURCE) R_Mesh_TexBindCubeMap(3, R_GetTexture(r_shadow_rtlight->currentcubemap)); - //if (r_glsl_permutation->loc_Texture_FogMask >= 0) R_Mesh_TexBind(4, R_GetTexture(r_texture_fogattenuation)); + if (r_glsl_permutation->loc_Texture_FogMask >= 0) R_Mesh_TexBind(4, R_GetTexture(r_texture_fogattenuation)); if (r_glsl_permutation->loc_Texture_Pants >= 0) R_Mesh_TexBind(5, R_GetTexture(texture->skin.pants)); if (r_glsl_permutation->loc_Texture_Shirt >= 0) R_Mesh_TexBind(6, R_GetTexture(texture->skin.shirt)); - //if (r_glsl_permutation->loc_Texture_Lightmap >= 0) R_Mesh_TexBind(7, R_GetTexture(r_texture_white)); - //if (r_glsl_permutation->loc_Texture_Deluxemap >= 0) R_Mesh_TexBind(8, R_GetTexture(r_texture_blanknormalmap)); + if (r_glsl_permutation->loc_Texture_Lightmap >= 0) R_Mesh_TexBind(7, R_GetTexture(r_texture_white)); + if (r_glsl_permutation->loc_Texture_Deluxemap >= 0) R_Mesh_TexBind(8, R_GetTexture(r_texture_blanknormalmap)); if (r_glsl_permutation->loc_Texture_Glow >= 0) R_Mesh_TexBind(9, R_GetTexture(texture->skin.glow)); if (r_glsl_permutation->loc_FogColor >= 0) { -- 2.39.2