]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - gl_rmain.c
host: Return to main() if the loop breaks and Sys_Quit from there
[xonotic/darkplaces.git] / gl_rmain.c
index 08c76845f23b7b63b48b7e38646f083acc2bac4f..9773bdd3c46b0ab80b3171291c78ddf90f2a5f38 100644 (file)
@@ -1370,7 +1370,7 @@ static void R_SetupShader_SetPermutationGLSL(unsigned int mode, uint64_t permuta
                {
                        if (!r_glsl_permutation->compiled)
                        {
-                               Con_DPrintf("Compiling shader mode %u permutation %"PRIx64"\n", mode, permutation);
+                               Con_DPrintf("Compiling shader mode %u permutation %" PRIx64 "\n", mode, permutation);
                                R_GLSL_CompilePermutation(perm, mode, permutation);
                        }
                        if (!r_glsl_permutation->program)
@@ -4295,12 +4295,16 @@ void R_HDR_UpdateIrisAdaptation(const vec3_t point)
                Cvar_SetValueQuick(&r_hdr_irisadaptation_value, 1.0f);
 }
 
+extern cvar_t r_lockvisibility;
+extern cvar_t r_lockpvs;
+
 static void R_View_SetFrustum(const int *scissor)
 {
        int i;
        double fpx = +1, fnx = -1, fpy = +1, fny = -1;
        vec3_t forward, left, up, origin, v;
-
+       if(r_lockvisibility.integer || r_lockpvs.integer)
+               return;
        if(scissor)
        {
                // flipped x coordinates (because x points left here)
@@ -4728,7 +4732,7 @@ static void R_Water_StartFrame(int viewwidth, int viewheight)
        waterwidth = (int)bound(16, viewwidth * r_water_resolutionmultiplier.value, viewwidth);
        waterheight = (int)bound(16, viewheight * r_water_resolutionmultiplier.value, viewheight);
 
-       if (!r_water.integer || r_showsurfaces.integer)
+       if (!r_water.integer || r_showsurfaces.integer || r_lockvisibility.integer || r_lockpvs.integer)
                waterwidth = waterheight = 0;
 
        // set up variables that will be used in shader setup