]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
expose r_refdef.view.quality to CSQC R_SetView VF_MINFPS_QUALITY
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 17 Nov 2011 13:06:21 +0000 (13:06 +0000)
committerRudolf Polzer <divverent@xonotic.org>
Sat, 19 Nov 2011 12:59:31 +0000 (13:59 +0100)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11562 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=d438d686e33ea33d17e8b68a6d25359881639b6d

clvm_cmds.c
csprogs.h

index f07cf854b2535918929c3508540ee4441f649fa4..094f550e389dedbcef67530d70bd552ad6873a98 100644 (file)
@@ -911,6 +911,9 @@ static void VM_CL_R_SetView (prvm_prog_t *prog)
                case VF_FOG_FADEDEPTH:
                        PRVM_G_FLOAT(OFS_RETURN) = r_refdef.fog_fadedepth;
                        break;
+               case VF_MINFPS_QUALITY:
+                       PRVM_G_FLOAT(OFS_RETURN) = r_refdef.view.quality;
+                       break;
                default:
                        PRVM_G_FLOAT(OFS_RETURN) = 0;
                        VM_Warning(prog, "VM_CL_R_GetView : unknown parm %i\n", c);
@@ -1061,6 +1064,9 @@ static void VM_CL_R_SetView (prvm_prog_t *prog)
        case VF_FOG_FADEDEPTH:
                r_refdef.fog_fadedepth = k;
                break;
+       case VF_MINFPS_QUALITY:
+               r_refdef.view.quality = k;
+               break;
        default:
                PRVM_G_FLOAT(OFS_RETURN) = 0;
                VM_Warning(prog, "VM_CL_R_SetView : unknown parm %i\n", c);
index 2aba12b389140b9ad5de7595b191ebdcf324a677..67fd489a2c7f1b0fb6a9db88587bfd4ac9bbb2c6 100644 (file)
--- a/csprogs.h
+++ b/csprogs.h
@@ -49,8 +49,8 @@
 #define VF_FOG_END             209 //(float)
 #define VF_FOG_HEIGHT          210 //(float)
 #define VF_FOG_FADEDEPTH       211 //(float)
-
 #define VF_MAINVIEW            212 //(float)
+#define VF_MINFPS_QUALITY      213 //(float)
 
 #define RF_VIEWMODEL           1       // The entity is never drawn in mirrors. In engines with realtime lighting, it casts no shadows.
 #define RF_EXTERNALMODEL       2       // The entity is appears in mirrors but not in the normal view. It does still cast shadows in engines with realtime lighting.