diff --git a/engine/client/wad.c b/engine/client/wad.c index da6fe69e9..d8611a305 100644 --- a/engine/client/wad.c +++ b/engine/client/wad.c @@ -381,8 +381,6 @@ qbyte *W_ConvertWAD3Texture(miptex_t *tex, size_t lumpsize, int *width, int *hei if (tex->name[0] == '{') alpha = 1; - else if (!strncmp(tex->name, "window", 6) || !strncmp(tex->name, "glass", 5)) - alpha = 2; if (tex->width > 0x10000 || tex->height > 0x10000) return NULL; diff --git a/engine/gl/gl_model.c b/engine/gl/gl_model.c index 8c70107ea..ba2976826 100644 --- a/engine/gl/gl_model.c +++ b/engine/gl/gl_model.c @@ -4145,11 +4145,7 @@ static qboolean Mod_LoadFaces (model_t *loadmodel, bspx_header_t *bspx, qbyte *m out->flags |= (SURF_DRAWALPHA); continue; } - if (!Q_strncmp(out->texinfo->texture->name,"glass",5)) // alpha - { - out->flags |= (SURF_DRAWALPHA); - continue; - } + if (out->flags & SURF_DRAWALPHA) out->flags &= ~SURF_DRAWALPHA; } diff --git a/engine/gl/gl_shader.c b/engine/gl/gl_shader.c index 04bb85336..63c6504fd 100644 --- a/engine/gl/gl_shader.c +++ b/engine/gl/gl_shader.c @@ -43,6 +43,7 @@ sh_config_t sh_config; cvar_t r_vertexlight = CVARFD("r_vertexlight", "0", CVAR_SHADERSYSTEM, "Hack loaded shaders to remove detail pass and lightmap sampling for faster rendering."); cvar_t r_forceprogramify = CVARAFD("r_forceprogramify", "0", "dpcompat_makeshitup", CVAR_SHADERSYSTEM, "Reduce the shader to a single texture, and then make stuff up about its mother. The resulting fist fight results in more colour when you shine a light upon its face.\nSet to 2 to ignore 'depthfunc equal' and 'tcmod scale' in order to tolerate bizzare shaders made for a bizzare engine.\nBecause most shaders made for DP are by people who _clearly_ have no idea what the heck they're doing, you'll typically need the '2' setting."); cvar_t dpcompat_nopremulpics = CVARFD("dpcompat_nopremulpics", "0", CVAR_SHADERSYSTEM, "By default FTE uses premultiplied alpha for hud/2d images, while DP does not (which results in halos with low-res content). Unfortunately DDS files would need to be recompressed, resulting in visible issues."); + extern cvar_t r_glsl_offsetmapping_reliefmapping; extern cvar_t r_drawflat; extern cvar_t r_shaderblobs; @@ -6766,21 +6767,6 @@ void Shader_DefaultBSPQ1(parsestate_t *ps, const char *shortname, const void *ar ); } - /*Hack: note that halflife would normally expect you to use rendermode/renderampt*/ - if (!builtin && (!strncmp(shortname, "glass", 5)/* || !strncmp(shortname, "window", 6)*/)) - { - /*alpha bended*/ - builtin = ( - "{\n" - "{\n" - "map $diffuse\n" - "tcgen base\n" - "blendfunc blend\n" - "}\n" - "}\n" - ); - } - if (builtin) Shader_DefaultScript(ps, shortname, builtin); else