realtime dlights are now overridden by gl_flashblend (as was intended)
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Fri, 4 Feb 2005 10:30:36 +0000 (10:30 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Fri, 4 Feb 2005 10:30:36 +0000 (10:30 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4999 d7cf8633-e32d-0410-b094-e92efae38249

gl_rmain.c
r_light.c
render.h

index b127b38..ccf6be3 100644 (file)
@@ -313,7 +313,7 @@ static float R_FarClip(vec3_t origin, vec3_t direction, vec_t startfarclip)
                R_FarClip_Box(r_refdef.worldmodel->normalmins, r_refdef.worldmodel->normalmaxs);
        for (i = 0;i < r_refdef.numentities;i++)
                R_FarClip_Box(r_refdef.entities[i]->mins, r_refdef.entities[i]->maxs);
-       
+
        return r_farclip_meshfarclip - r_farclip_directiondist;
 }
 
@@ -739,7 +739,7 @@ void R_RenderView(void)
        GL_ColorMask(r_refdef.colormask[0], r_refdef.colormask[1], r_refdef.colormask[2], 1);
        r_rtworld = r_shadow_realtime_world.integer;
        r_rtworldshadows = r_shadow_realtime_world_shadows.integer && gl_stencil;
-       r_rtdlight = r_shadow_realtime_world.integer || r_shadow_realtime_dlight.integer;
+       r_rtdlight = (r_shadow_realtime_world.integer || r_shadow_realtime_dlight.integer) && !gl_flashblend.integer;
        r_rtdlightshadows = r_rtdlight && (r_rtworld ? r_shadow_realtime_world_dlightshadows.integer : r_shadow_realtime_dlight_shadows.integer) && gl_stencil;
        r_lightmapintensity = r_rtworld ? r_shadow_realtime_world_lightmaps.value : 1;
 
@@ -765,7 +765,7 @@ void R_RenderView(void)
 
        R_BlendView();
        R_TimeReport("blendview");
-       
+
        GL_Scissor(0, 0, vid.realwidth, vid.realheight);
        GL_ScissorTest(false);
 }
index 0dc8bee..c431a86 100644 (file)
--- a/r_light.c
+++ b/r_light.c
@@ -29,7 +29,7 @@ int r_numdlights = 0;
 cvar_t r_modellights = {CVAR_SAVE, "r_modellights", "4"};
 cvar_t r_vismarklights = {0, "r_vismarklights", "1"};
 cvar_t r_coronas = {CVAR_SAVE, "r_coronas", "1"};
-cvar_t gl_flashblend = {CVAR_SAVE, "gl_flashblend", "1"};
+cvar_t gl_flashblend = {CVAR_SAVE, "gl_flashblend", "0"};
 
 static rtexture_t *lightcorona;
 static rtexturepool_t *lighttexturepool;
index e9cd43b..46cc4e6 100644 (file)
--- a/render.h
+++ b/render.h
@@ -56,6 +56,7 @@ extern char r_speeds_string[1024];
 
 // lighting stuff
 extern cvar_t r_ambient;
+extern cvar_t gl_flashblend;
 
 // vis stuff
 extern cvar_t r_novis;