Fix r_softwarebanding. Again.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5412 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
75e927c030
commit
48694bb795
2 changed files with 4 additions and 4 deletions
|
@ -3198,7 +3198,7 @@ YOU SHOULD NOT EDIT THIS FILE BY HAND
|
|||
"#endif\n"
|
||||
|
||||
"#ifdef EIGHTBIT\n"
|
||||
"vec3 lightlev = light;\n"
|
||||
"vec3 lightlev = light.rgb;\n"
|
||||
//FIXME: with this extra flag, half the permutations are redundant.
|
||||
"lightlev *= 0.5; //counter the fact that the colourmap contains overbright values and logically ranges from 0 to 2 intead of to 1.\n"
|
||||
"float pal = texture2D(s_paletted, tc).r; //the palette index. hopefully not interpolated.\n"
|
||||
|
@ -3206,7 +3206,7 @@ YOU SHOULD NOT EDIT THIS FILE BY HAND
|
|||
"col.r = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.r)).r; //do 3 lookups. this is to cope with lit files, would be a waste to not support those.\n"
|
||||
"col.g = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.g)).g; //its not very softwarey, but re-palettizing is ugly.\n"
|
||||
"col.b = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.b)).b; //without lits, it should be identical.\n"
|
||||
"col.a = (pal<1.0)?1.0:0.0;\n"
|
||||
"col.a = (pal<1.0)?light.a:0.0;\n"
|
||||
"#else\n"
|
||||
"col = texture2D(s_diffuse, tc);\n"
|
||||
"#ifdef UPPER\n"
|
||||
|
|
|
@ -253,7 +253,7 @@ void main ()
|
|||
#endif
|
||||
|
||||
#ifdef EIGHTBIT
|
||||
vec3 lightlev = light;
|
||||
vec3 lightlev = light.rgb;
|
||||
//FIXME: with this extra flag, half the permutations are redundant.
|
||||
lightlev *= 0.5; //counter the fact that the colourmap contains overbright values and logically ranges from 0 to 2 intead of to 1.
|
||||
float pal = texture2D(s_paletted, tc).r; //the palette index. hopefully not interpolated.
|
||||
|
@ -261,7 +261,7 @@ void main ()
|
|||
col.r = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.r)).r; //do 3 lookups. this is to cope with lit files, would be a waste to not support those.
|
||||
col.g = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.g)).g; //its not very softwarey, but re-palettizing is ugly.
|
||||
col.b = texture2D(s_colourmap, vec2(pal, 1.0-lightlev.b)).b; //without lits, it should be identical.
|
||||
col.a = (pal<1.0)?1.0:0.0;
|
||||
col.a = (pal<1.0)?light.a:0.0;
|
||||
#else
|
||||
col = texture2D(s_diffuse, tc);
|
||||
#ifdef UPPER
|
||||
|
|
Loading…
Reference in a new issue