Consistent sorting, so it doesn't break when toggled.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3672 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2010-11-28 19:10:34 +00:00
parent 3f176505d8
commit 0a00c81189

View file

@ -2746,7 +2746,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
{ {
builtin = ( builtin = (
"{\n" "{\n"
"sort seethrough\n" "sort blend\n"
"surfaceparm nodraw\n" "surfaceparm nodraw\n"
"surfaceparm nodlight\n" "surfaceparm nodlight\n"
"}\n" "}\n"
@ -2756,7 +2756,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
{ {
builtin = ( builtin = (
"{\n" "{\n"
"sort seethrough\n" "sort blend\n"
"{\n" "{\n"
"map $whiteimage\n" "map $whiteimage\n"
"rgbgen const $r_fastturbcolour\n" "rgbgen const $r_fastturbcolour\n"
@ -2770,6 +2770,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
{ {
builtin = ( builtin = (
"{\n" "{\n"
"sort blend\n"
"program\n" "program\n"
"{\n" "{\n"
"#ifdef VERTEX_SHADER\n" "#ifdef VERTEX_SHADER\n"
@ -2805,7 +2806,6 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
"if r_wateralpha != 1\n" "if r_wateralpha != 1\n"
"[\n" "[\n"
"param cvarf r_wateralpha wateralpha\n" "param cvarf r_wateralpha wateralpha\n"
"sort blend\n"
"{\n" "{\n"
"map $diffuse\n" "map $diffuse\n"
"blendfunc gl_src_alpha gl_one_minus_src_alpha\n" "blendfunc gl_src_alpha gl_one_minus_src_alpha\n"
@ -2814,7 +2814,6 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
"if r_wateralpha == 1\n" "if r_wateralpha == 1\n"
"[\n" "[\n"
"param constf 1 wateralpha\n" "param constf 1 wateralpha\n"
"sort opaque\n"
"{\n" "{\n"
"map $diffuse\n" "map $diffuse\n"
"}\n" "}\n"
@ -2834,6 +2833,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
"alphagen const $r_wateralpha\n" "alphagen const $r_wateralpha\n"
"blendfunc blend\n" "blendfunc blend\n"
"}\n" "}\n"
"sort blend\n"
"surfaceparm nodlight\n" "surfaceparm nodlight\n"
"}\n" "}\n"
); );
@ -2846,6 +2846,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
"map $diffuse\n" "map $diffuse\n"
"tcmod turb 0 0 3 0.1\n" "tcmod turb 0 0 3 0.1\n"
"}\n" "}\n"
"sort blend\n"
"surfaceparm nodlight\n" "surfaceparm nodlight\n"
"}\n" "}\n"
); );
@ -2857,6 +2858,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
if (r_fastsky.ival) if (r_fastsky.ival)
builtin = ( builtin = (
"{\n" "{\n"
"sort sky\n"
"{\n" "{\n"
"map $whiteimage\n" "map $whiteimage\n"
"rgbgen const $r_fastskycolour\n" "rgbgen const $r_fastskycolour\n"
@ -2867,6 +2869,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
else if (*r_skyboxname.string) else if (*r_skyboxname.string)
builtin = ( builtin = (
"{\n" "{\n"
"sort sky\n"
"skyparms $r_skybox - -\n" "skyparms $r_skybox - -\n"
"surfaceparm nodlight\n" "surfaceparm nodlight\n"
"}\n" "}\n"
@ -2875,6 +2878,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
else if (qrenderer == QR_OPENGL && gl_config.arb_shader_objects) else if (qrenderer == QR_OPENGL && gl_config.arb_shader_objects)
builtin = ( builtin = (
"{\n" "{\n"
"sort sky\n"
"program\n" "program\n"
"{\n" "{\n"
"#ifdef VERTEX_SHADER\n" "#ifdef VERTEX_SHADER\n"
@ -2933,6 +2937,7 @@ void Shader_DefaultBSPQ1(char *shortname, shader_t *s, const void *args)
else else
builtin = ( builtin = (
"{\n" "{\n"
"sort sky\n"
"skyparms - 512 -\n" "skyparms - 512 -\n"
/*WARNING: these values are not authentic quake, only close aproximations*/ /*WARNING: these values are not authentic quake, only close aproximations*/
"{\n" "{\n"