]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - vid_shared.c
moved ixtable definition and initialization code to mathlib (and added Mathlib_Init...
[xonotic/darkplaces.git] / vid_shared.c
index 589c59dc4365d4751f98461be2e6bd1b0c889f95..8852c35942bcd4c3e9948ee0154d76b8c9256d66 100644 (file)
@@ -1,3 +1,34 @@
 
 #include "quakedef.h"
 
+// LordHavoc: these are only set in wgl
+qboolean isG200 = false; // LordHavoc: the Matrox G200 can't do per pixel alpha, and it uses a D3D driver for GL... ugh...
+qboolean isRagePro = false; // LordHavoc: the ATI Rage Pro has limitations with per pixel alpha (the color scaler does not apply to per pixel alpha images...), although not as bad as a G200.
+
+// LordHavoc: compiled vertex array support
+qboolean gl_supportslockarrays = false;
+// LordHavoc: ARB multitexture support
+qboolean gl_mtexable = false;
+int gl_mtex_enum = 0;
+
+cvar_t vid_mode = {0, "vid_mode", "0"};
+cvar_t vid_mouse = {CVAR_SAVE, "vid_mouse", "1"};
+cvar_t vid_fullscreen = {0, "vid_fullscreen", "1"};
+
+void (GLAPIENTRY *qglMTexCoord2f) (GLenum, GLfloat, GLfloat);
+void (GLAPIENTRY *qglSelectTexture) (GLenum);
+void (GLAPIENTRY *qglLockArraysEXT) (GLint first, GLint count);
+void (GLAPIENTRY *qglUnlockArraysEXT) (void);
+
+void Force_CenterView_f (void)
+{
+       cl.viewangles[PITCH] = 0;
+}
+
+void VID_InitCvars(void)
+{
+       Cvar_RegisterVariable(&vid_mode);
+       Cvar_RegisterVariable(&vid_mouse);
+       Cvar_RegisterVariable(&vid_fullscreen);
+       Cmd_AddCommand("force_centerview", Force_CenterView_f);
+}