mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 19:20:46 +00:00
clean up "renderer setup" menu a bit so we can put polymer shit in it later
git-svn-id: https://svn.eduke32.com/eduke32@1534 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
cfc8b8d3da
commit
4e4ef98ae6
9 changed files with 82 additions and 85 deletions
|
@ -595,7 +595,7 @@ extern int32_t glanisotropy;
|
||||||
extern int32_t glusetexcompr;
|
extern int32_t glusetexcompr;
|
||||||
extern int32_t gltexfiltermode;
|
extern int32_t gltexfiltermode;
|
||||||
extern int32_t glredbluemode;
|
extern int32_t glredbluemode;
|
||||||
extern int32_t glusetexcache, glusetexcachecompression;
|
extern int32_t glusetexcache;
|
||||||
extern int32_t glmultisample, glnvmultisamplehint;
|
extern int32_t glmultisample, glnvmultisamplehint;
|
||||||
extern int32_t glwidescreen, glprojectionhacks;
|
extern int32_t glwidescreen, glprojectionhacks;
|
||||||
extern int32_t gltexmaxsize;
|
extern int32_t gltexmaxsize;
|
||||||
|
|
|
@ -155,16 +155,10 @@ int32_t loadsetup(const char *fn)
|
||||||
if (readconfig(fp, "usemodels", val, VL) > 0) usemodels = Batoi(val)?1:0;
|
if (readconfig(fp, "usemodels", val, VL) > 0) usemodels = Batoi(val)?1:0;
|
||||||
if (readconfig(fp, "usehightile", val, VL) > 0) usehightile = Batoi(val)?1:0;
|
if (readconfig(fp, "usehightile", val, VL) > 0) usehightile = Batoi(val)?1:0;
|
||||||
|
|
||||||
glusetexcache = glusetexcachecompression = -1;
|
glusetexcache = -1;
|
||||||
if (readconfig(fp, "glusetexcache", val, VL) > 0)
|
if (readconfig(fp, "glusetexcache", val, VL) > 0)
|
||||||
{
|
{
|
||||||
if (Batoi(val) != 0) glusetexcache = 1;
|
glusetexcache = clamp(Batoi(val), 0, 2);
|
||||||
else glusetexcache = 0;
|
|
||||||
}
|
|
||||||
if (readconfig(fp, "glusetexcachecompression", val, VL) > 0)
|
|
||||||
{
|
|
||||||
if (Batoi(val) != 0) glusetexcachecompression = 1;
|
|
||||||
else glusetexcachecompression = 0;
|
|
||||||
}
|
}
|
||||||
if (readconfig(fp, "gltexfiltermode", val, VL) > 0)
|
if (readconfig(fp, "gltexfiltermode", val, VL) > 0)
|
||||||
{
|
{
|
||||||
|
@ -318,7 +312,6 @@ int32_t writesetup(const char *fn)
|
||||||
"usemodels = %d\n"
|
"usemodels = %d\n"
|
||||||
"usehightile = %d\n"
|
"usehightile = %d\n"
|
||||||
"glusetexcache = %d\n"
|
"glusetexcache = %d\n"
|
||||||
"glusetexcachecompression = %d\n"
|
|
||||||
"gltexfiltermode = %d\n"
|
"gltexfiltermode = %d\n"
|
||||||
"glanisotropy = %d\n"
|
"glanisotropy = %d\n"
|
||||||
"\n"
|
"\n"
|
||||||
|
@ -463,7 +456,7 @@ int32_t writesetup(const char *fn)
|
||||||
editorgridextent,
|
editorgridextent,
|
||||||
#if defined(POLYMOST) && defined(USE_OPENGL)
|
#if defined(POLYMOST) && defined(USE_OPENGL)
|
||||||
usemodels, usehightile,
|
usemodels, usehightile,
|
||||||
glusetexcache, glusetexcachecompression, gltexfiltermode, glanisotropy,
|
glusetexcache, gltexfiltermode, glanisotropy,
|
||||||
#endif
|
#endif
|
||||||
#ifdef RENDERTYPEWIN
|
#ifdef RENDERTYPEWIN
|
||||||
maxrefreshfreq, windowpos, windowx, windowy,
|
maxrefreshfreq, windowpos, windowx, windowy,
|
||||||
|
|
|
@ -573,8 +573,8 @@ int32_t mdloadskin_trytexcache(char *fn, int32_t len, int32_t pal, char effect,
|
||||||
head->quality = B_LITTLE32(head->quality);
|
head->quality = B_LITTLE32(head->quality);
|
||||||
|
|
||||||
if (head->quality != r_downsize) goto failure;
|
if (head->quality != r_downsize) goto failure;
|
||||||
if ((head->flags & 4) && !glusetexcachecompression) goto failure;
|
if ((head->flags & 4) && glusetexcache != 2) goto failure;
|
||||||
if (!(head->flags & 4) && glusetexcachecompression) goto failure;
|
if (!(head->flags & 4) && glusetexcache == 2) goto failure;
|
||||||
if (gltexmaxsize && (head->xdim > (1<<gltexmaxsize) || head->ydim > (1<<gltexmaxsize))) goto failure;
|
if (gltexmaxsize && (head->xdim > (1<<gltexmaxsize) || head->ydim > (1<<gltexmaxsize))) goto failure;
|
||||||
if (!glinfo.texnpot && (head->flags & 1)) goto failure;
|
if (!glinfo.texnpot && (head->flags & 1)) goto failure;
|
||||||
|
|
||||||
|
|
|
@ -138,8 +138,7 @@ struct glfiltermodes glfiltermodes[numglfiltermodes] =
|
||||||
int32_t glanisotropy = 1; // 0 = maximum supported by card
|
int32_t glanisotropy = 1; // 0 = maximum supported by card
|
||||||
int32_t glusetexcompr = 1;
|
int32_t glusetexcompr = 1;
|
||||||
int32_t gltexfiltermode = 2; // GL_NEAREST_MIPMAP_NEAREST
|
int32_t gltexfiltermode = 2; // GL_NEAREST_MIPMAP_NEAREST
|
||||||
int32_t glusetexcache = 0;
|
int32_t glusetexcache = 2;
|
||||||
int32_t glusetexcachecompression = 1;
|
|
||||||
int32_t glmultisample = 0, glnvmultisamplehint = 0;
|
int32_t glmultisample = 0, glnvmultisamplehint = 0;
|
||||||
int32_t gltexmaxsize = 0; // 0 means autodetection on first run
|
int32_t gltexmaxsize = 0; // 0 means autodetection on first run
|
||||||
int32_t gltexmiplevel = 0; // discards this many mipmap levels
|
int32_t gltexmiplevel = 0; // discards this many mipmap levels
|
||||||
|
@ -1300,8 +1299,8 @@ int32_t trytexcache(char *fn, int32_t len, int32_t dameth, char effect, texcache
|
||||||
head->flags = B_LITTLE32(head->flags);
|
head->flags = B_LITTLE32(head->flags);
|
||||||
head->quality = B_LITTLE32(head->quality);
|
head->quality = B_LITTLE32(head->quality);
|
||||||
|
|
||||||
if ((head->flags & 4) && !glusetexcachecompression) goto failure;
|
if ((head->flags & 4) && glusetexcache != 2) goto failure;
|
||||||
if (!(head->flags & 4) && glusetexcachecompression) goto failure;
|
if (!(head->flags & 4) && glusetexcache == 2) goto failure;
|
||||||
|
|
||||||
if (!(head->flags & 8) && head->quality != r_downsize) return -1; // handle nocompress
|
if (!(head->flags & 8) && head->quality != r_downsize) return -1; // handle nocompress
|
||||||
if (gltexmaxsize && (head->xdim > (1<<gltexmaxsize) || head->ydim > (1<<gltexmaxsize))) goto failure;
|
if (gltexmaxsize && (head->xdim > (1<<gltexmaxsize) || head->ydim > (1<<gltexmaxsize))) goto failure;
|
||||||
|
@ -1361,7 +1360,7 @@ void writexcache(char *fn, int32_t len, int32_t dameth, char effect, texcachehea
|
||||||
|
|
||||||
Bmemcpy(head->magic, "PMST", 4); // sizes are set by caller
|
Bmemcpy(head->magic, "PMST", 4); // sizes are set by caller
|
||||||
|
|
||||||
if (glusetexcachecompression) head->flags |= 4;
|
if (glusetexcache == 2) head->flags |= 4;
|
||||||
|
|
||||||
head->xdim = B_LITTLE32(head->xdim);
|
head->xdim = B_LITTLE32(head->xdim);
|
||||||
head->ydim = B_LITTLE32(head->ydim);
|
head->ydim = B_LITTLE32(head->ydim);
|
||||||
|
@ -5937,8 +5936,7 @@ void polymost_initosdfuncs(void)
|
||||||
{ "r_redbluemode","r_redbluemode: enable/disable experimental OpenGL red-blue glasses mode",(void *)&glredbluemode, CVAR_BOOL, 0, 0, 1 },
|
{ "r_redbluemode","r_redbluemode: enable/disable experimental OpenGL red-blue glasses mode",(void *)&glredbluemode, CVAR_BOOL, 0, 0, 1 },
|
||||||
{ "r_shadescale","r_shadescale: multiplier for lighting",(void *)&shadescale, CVAR_FLOAT, 0, 0, 10 },
|
{ "r_shadescale","r_shadescale: multiplier for lighting",(void *)&shadescale, CVAR_FLOAT, 0, 0, 10 },
|
||||||
{ "r_swapinterval","r_swapinterval: sets the GL swap interval (VSync)",(void *)&vsync, CVAR_BOOL|CVAR_FUNCPTR, 0, 0, 1 },
|
{ "r_swapinterval","r_swapinterval: sets the GL swap interval (VSync)",(void *)&vsync, CVAR_BOOL|CVAR_FUNCPTR, 0, 0, 1 },
|
||||||
{ "r_texcachecompression","r_texcachecompression: enable/disable compression of files in the OpenGL compressed texture cache",(void *)&glusetexcachecompression, CVAR_BOOL, 0, 0, 1 },
|
{ "r_texcache","r_texcache: enable/disable OpenGL compressed texture cache",(void *)&glusetexcache, CVAR_INT, 0, 0, 2 },
|
||||||
{ "r_texcache","r_texcache: enable/disable OpenGL compressed texture cache",(void *)&glusetexcache, CVAR_BOOL, 0, 0, 1 },
|
|
||||||
{ "r_texcompr","r_texcompr: enable/disable OpenGL texture compression",(void *)&glusetexcompr, CVAR_BOOL, 0, 0, 1 },
|
{ "r_texcompr","r_texcompr: enable/disable OpenGL texture compression",(void *)&glusetexcompr, CVAR_BOOL, 0, 0, 1 },
|
||||||
{ "r_textureanisotropy", "r_textureanisotropy: changes the OpenGL texture anisotropy setting", (void *)&glanisotropy, CVAR_INT|CVAR_FUNCPTR, 0, 0, 16 },
|
{ "r_textureanisotropy", "r_textureanisotropy: changes the OpenGL texture anisotropy setting", (void *)&glanisotropy, CVAR_INT|CVAR_FUNCPTR, 0, 0, 16 },
|
||||||
{ "r_texturemaxsize","r_texturemaxsize: changes the maximum OpenGL texture size limit",(void *)&gltexmaxsize, CVAR_INT, 0, 0, 4096 },
|
{ "r_texturemaxsize","r_texturemaxsize: changes the maximum OpenGL texture size limit",(void *)&gltexmaxsize, CVAR_INT, 0, 0, 4096 },
|
||||||
|
@ -6094,7 +6092,7 @@ int32_t dxtfilter(int32_t fil, texcachepicture *pict, char *pic, void *midbuf, c
|
||||||
void *writebuf;
|
void *writebuf;
|
||||||
#if (USEKENFILTER == 0)
|
#if (USEKENFILTER == 0)
|
||||||
uint32_t cleng,j;
|
uint32_t cleng,j;
|
||||||
if (glusetexcachecompression)
|
if (glusetexcache == 2)
|
||||||
{
|
{
|
||||||
#ifdef USELZF
|
#ifdef USELZF
|
||||||
cleng = fastlz_compress(pic, miplen, packbuf/*, miplen-1*/);
|
cleng = fastlz_compress(pic, miplen, packbuf/*, miplen-1*/);
|
||||||
|
@ -6135,7 +6133,7 @@ int32_t dxtfilter(int32_t fil, texcachepicture *pict, char *pic, void *midbuf, c
|
||||||
for (k=0; k<8; k++) *cptr++ = pic[k];
|
for (k=0; k<8; k++) *cptr++ = pic[k];
|
||||||
for (j=stride; (unsigned)j<miplen; j+=stride)
|
for (j=stride; (unsigned)j<miplen; j+=stride)
|
||||||
for (k=0; k<8; k++) *cptr++ = pic[j+k];
|
for (k=0; k<8; k++) *cptr++ = pic[j+k];
|
||||||
if (glusetexcachecompression)
|
if (glusetexcache == 2)
|
||||||
{
|
{
|
||||||
#ifdef USELZF
|
#ifdef USELZF
|
||||||
j = (miplen/stride)<<3;
|
j = (miplen/stride)<<3;
|
||||||
|
@ -6166,7 +6164,7 @@ int32_t dxtfilter(int32_t fil, texcachepicture *pict, char *pic, void *midbuf, c
|
||||||
for (k=0; k<=2; k+=2)
|
for (k=0; k<=2; k+=2)
|
||||||
for (j=0; (unsigned)j<miplen; j+=stride)
|
for (j=0; (unsigned)j<miplen; j+=stride)
|
||||||
{ *(int16_t *)cptr = hicosub(*(int16_t *)(&pic[offs+j+k])); cptr += 2; }
|
{ *(int16_t *)cptr = hicosub(*(int16_t *)(&pic[offs+j+k])); cptr += 2; }
|
||||||
if (glusetexcachecompression)
|
if (glusetexcache == 2)
|
||||||
{
|
{
|
||||||
#ifdef USELZF
|
#ifdef USELZF
|
||||||
j = (miplen/stride)<<2;
|
j = (miplen/stride)<<2;
|
||||||
|
@ -6202,7 +6200,7 @@ int32_t dxtfilter(int32_t fil, texcachepicture *pict, char *pic, void *midbuf, c
|
||||||
cptr[3] = ((c2[0]>>6)&3) + (((c2[1]>>6)&3)<<2) + (((c2[2]>>6)&3)<<4) + (((c2[3]>>6)&3)<<6);
|
cptr[3] = ((c2[0]>>6)&3) + (((c2[1]>>6)&3)<<2) + (((c2[2]>>6)&3)<<4) + (((c2[3]>>6)&3)<<6);
|
||||||
cptr += 4;
|
cptr += 4;
|
||||||
}
|
}
|
||||||
if (glusetexcachecompression)
|
if (glusetexcache == 2)
|
||||||
{
|
{
|
||||||
#ifdef USELZF
|
#ifdef USELZF
|
||||||
j = (miplen/stride)<<2;
|
j = (miplen/stride)<<2;
|
||||||
|
|
|
@ -9948,12 +9948,12 @@ int32_t ExtInit(void)
|
||||||
bpp = 32;
|
bpp = 32;
|
||||||
|
|
||||||
#if defined(POLYMOST) && defined(USE_OPENGL)
|
#if defined(POLYMOST) && defined(USE_OPENGL)
|
||||||
glusetexcache = glusetexcachecompression = -1;
|
glusetexcache = -1;
|
||||||
|
|
||||||
initprintf("Using config file '%s'.\n",setupfilename);
|
initprintf("Using config file '%s'.\n",setupfilename);
|
||||||
if (loadsetup(setupfilename) < 0) initprintf("Configuration file not found, using defaults.\n"), rv = 1;
|
if (loadsetup(setupfilename) < 0) initprintf("Configuration file not found, using defaults.\n"), rv = 1;
|
||||||
|
|
||||||
if (glusetexcache == -1 || glusetexcachecompression == -1)
|
if (glusetexcache == -1)
|
||||||
{
|
{
|
||||||
int32_t i;
|
int32_t i;
|
||||||
#if 0
|
#if 0
|
||||||
|
@ -9964,8 +9964,8 @@ int32_t ExtInit(void)
|
||||||
i = 1;
|
i = 1;
|
||||||
#endif
|
#endif
|
||||||
if (i)
|
if (i)
|
||||||
glusetexcompr = glusetexcache = glusetexcachecompression = 1;
|
glusetexcompr = 1, glusetexcache = 2;
|
||||||
else glusetexcache = glusetexcachecompression = 0;
|
else glusetexcache = 0;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -795,7 +795,6 @@ int32_t CONFIG_ReadSetup(void)
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLTextureQuality", &r_downsize);
|
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLTextureQuality", &r_downsize);
|
||||||
r_downsizevar = r_downsize;
|
r_downsizevar = r_downsize;
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLUseCompressedTextureCache", &glusetexcache);
|
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLUseCompressedTextureCache", &glusetexcache);
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCacheCompression", &glusetexcachecompression);
|
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCompr", &glusetexcompr);
|
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCompr", &glusetexcompr);
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLVBOCount", &r_vbocount);
|
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLVBOCount", &r_vbocount);
|
||||||
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLVBOs", &r_vbos);
|
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "GLVBOs", &r_vbos);
|
||||||
|
@ -1104,7 +1103,6 @@ void CONFIG_WriteSetup(void)
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLTextureMode",gltexfiltermode,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLTextureMode",gltexfiltermode,FALSE,FALSE);
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLTextureQuality", r_downsize,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLTextureQuality", r_downsize,FALSE,FALSE);
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLUseCompressedTextureCache", glusetexcache,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLUseCompressedTextureCache", glusetexcache,FALSE,FALSE);
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCacheCompression", glusetexcachecompression,FALSE,FALSE);
|
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCompr",glusetexcompr,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLUseTextureCompr",glusetexcompr,FALSE,FALSE);
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLVBOCount", r_vbocount,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLVBOCount", r_vbocount,FALSE,FALSE);
|
||||||
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLVBOs", r_vbos,FALSE,FALSE);
|
SCRIPT_PutNumber(ud.config.scripthandle, "Screen Setup", "GLVBOs", r_vbos,FALSE,FALSE);
|
||||||
|
|
|
@ -10560,7 +10560,7 @@ void app_main(int32_t argc,const char **argv)
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(POLYMOST) && defined(USE_OPENGL)
|
#if defined(POLYMOST) && defined(USE_OPENGL)
|
||||||
glusetexcache = glusetexcachecompression = -1;
|
glusetexcache = -1;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -10623,7 +10623,7 @@ void app_main(int32_t argc,const char **argv)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(POLYMOST) && defined(USE_OPENGL)
|
#if defined(POLYMOST) && defined(USE_OPENGL)
|
||||||
if (glusetexcache == -1 || glusetexcachecompression == -1)
|
if (glusetexcache == -1)
|
||||||
{
|
{
|
||||||
#if 0
|
#if 0
|
||||||
i=wm_ynbox("Texture Cache",
|
i=wm_ynbox("Texture Cache",
|
||||||
|
@ -10632,8 +10632,8 @@ void app_main(int32_t argc,const char **argv)
|
||||||
#else
|
#else
|
||||||
i = 1;
|
i = 1;
|
||||||
#endif
|
#endif
|
||||||
if (i) ud.config.useprecache = glusetexcompr = glusetexcache = glusetexcachecompression = 1;
|
if (i) ud.config.useprecache = glusetexcompr = 1, glusetexcache = 2;
|
||||||
else glusetexcache = glusetexcachecompression = 0;
|
else glusetexcache = 0;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
#include "duke3d.h"
|
#include "duke3d.h"
|
||||||
|
|
||||||
const char *s_buildDate = "20091015";
|
const char *s_buildDate = "20091017";
|
||||||
char *MusicPtr = NULL;
|
char *MusicPtr = NULL;
|
||||||
int32_t g_musicSize;
|
int32_t g_musicSize;
|
||||||
|
|
||||||
|
|
|
@ -2401,23 +2401,18 @@ cheat_for_port_credits:
|
||||||
int32_t io, ii, yy, d=c+160+40, enabled;
|
int32_t io, ii, yy, d=c+160+40, enabled;
|
||||||
char *opts[] =
|
char *opts[] =
|
||||||
{
|
{
|
||||||
"Widescreen",
|
"Aspect ratio",
|
||||||
"Anisotropic filtering",
|
"Anisotropic filtering",
|
||||||
"Use VSync",
|
"Use VSync",
|
||||||
"Ambient light level",
|
"Ambient light level",
|
||||||
"-",
|
"-",
|
||||||
"Enable hires textures",
|
"Enable hires textures",
|
||||||
"Hires texture quality",
|
"Hires texture quality",
|
||||||
"Precache hires textures",
|
"Pre-load map textures",
|
||||||
"GL texture compression",
|
"On disk texture cache",
|
||||||
"Cache textures on disk",
|
|
||||||
"Compress disk cache",
|
|
||||||
"Use detail textures",
|
"Use detail textures",
|
||||||
"Use glow textures",
|
|
||||||
"-",
|
"-",
|
||||||
"Use models",
|
"Use models",
|
||||||
"Blend model animations",
|
|
||||||
"Model occlusion checking",
|
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -2455,9 +2450,44 @@ cheat_for_port_credits:
|
||||||
switch (io)
|
switch (io)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
|
if (getrendermode() == 3)
|
||||||
|
{
|
||||||
if (x==io) glwidescreen = 1-glwidescreen;
|
if (x==io) glwidescreen = 1-glwidescreen;
|
||||||
modval(0,1,(int32_t *)&glwidescreen,1,probey==io);
|
modval(0,1,(int32_t *)&glwidescreen,1,probey==io);
|
||||||
mgametextpal(d,yy, glwidescreen ? "Yes" : "No", MENUHIGHLIGHT(io), 0);
|
mgametextpal(d,yy, glwidescreen ? "Wide" : "Regular", MENUHIGHLIGHT(io), 0);
|
||||||
|
}
|
||||||
|
#ifdef POLYMER
|
||||||
|
else
|
||||||
|
{
|
||||||
|
float ratios[] = { 0.0, 1.33, 1.66, 1.78, 1.85, 2.35 };
|
||||||
|
|
||||||
|
int32_t j = (sizeof(ratios)/sizeof(ratios[0]));
|
||||||
|
|
||||||
|
for (i = 0; i<j; i++)
|
||||||
|
if (ratios[i] == pr_customaspect)
|
||||||
|
break;
|
||||||
|
|
||||||
|
modval(0,j-1,(int32_t *)&i,1,probey==io);
|
||||||
|
if (x == io)
|
||||||
|
{
|
||||||
|
i++;
|
||||||
|
if (i >= j)
|
||||||
|
i = 0;
|
||||||
|
}
|
||||||
|
if (i == j)
|
||||||
|
Bsprintf(tempbuf,"Custom");
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (i == 0) Bsprintf(tempbuf,"Auto");
|
||||||
|
else Bsprintf(tempbuf,"%.2f:1",ratios[i]);
|
||||||
|
|
||||||
|
if (ratios[i] != pr_customaspect)
|
||||||
|
pr_customaspect = ratios[i];
|
||||||
|
}
|
||||||
|
mgametextpal(d,yy,tempbuf, MENUHIGHLIGHT(io), 0);
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
{
|
{
|
||||||
|
@ -2526,52 +2556,30 @@ cheat_for_port_credits:
|
||||||
mgametextpal(d,yy, ud.config.useprecache ? "On" : "Off", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
mgametextpal(d,yy, ud.config.useprecache ? "On" : "Off", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
||||||
break;
|
break;
|
||||||
case 7:
|
case 7:
|
||||||
enabled = usehightile;
|
{
|
||||||
if (enabled && x==io) glusetexcompr = !glusetexcompr;
|
char *s[] = { "Off", "On", "Compress" };
|
||||||
if (enabled) modval(0,1,(int32_t *)&glusetexcompr,1,probey==io);
|
enabled = (glusetexcompr && usehightile);
|
||||||
mgametextpal(d,yy, glusetexcompr ? "On" : "Off", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
if (enabled && x==io)
|
||||||
|
{
|
||||||
|
glusetexcache++;
|
||||||
|
if (glusetexcache > 2)
|
||||||
|
glusetexcache = 0;
|
||||||
|
}
|
||||||
|
if (enabled) modval(0,2,(int32_t *)&glusetexcache,1,probey==io);
|
||||||
|
mgametextpal(d,yy, s[glusetexcache], enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 8:
|
case 8:
|
||||||
enabled = (glusetexcompr && usehightile);
|
|
||||||
if (enabled && x==io) glusetexcache = !glusetexcache;
|
|
||||||
if (enabled) modval(0,1,(int32_t *)&glusetexcache,1,probey==io);
|
|
||||||
mgametextpal(d,yy, glusetexcache ? "On" : "Off", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
|
||||||
break;
|
|
||||||
case 9:
|
|
||||||
enabled = (glusetexcompr && usehightile && glusetexcache);
|
|
||||||
if (enabled && x==io) glusetexcachecompression = !glusetexcachecompression;
|
|
||||||
if (enabled) modval(0,1,(int32_t *)&glusetexcachecompression,1,probey==io);
|
|
||||||
mgametextpal(d,yy, glusetexcachecompression ? "On" : "Off", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
|
||||||
break;
|
|
||||||
case 10:
|
|
||||||
enabled = usehightile;
|
enabled = usehightile;
|
||||||
if (enabled && x==io) r_detailmapping = !r_detailmapping;
|
if (enabled && x==io) r_detailmapping = !r_detailmapping;
|
||||||
if (enabled) modval(0,1,(int32_t *)&r_detailmapping,1,probey==io);
|
if (enabled) modval(0,1,(int32_t *)&r_detailmapping,1,probey==io);
|
||||||
mgametextpal(d,yy, r_detailmapping ? "Yes" : "No", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
mgametextpal(d,yy, r_detailmapping ? "Yes" : "No", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
||||||
break;
|
break;
|
||||||
case 11:
|
case 9:
|
||||||
enabled = usehightile;
|
|
||||||
if (enabled && x==io) r_glowmapping = !r_glowmapping;
|
|
||||||
if (enabled) modval(0,1,(int32_t *)&r_glowmapping,1,probey==io);
|
|
||||||
mgametextpal(d,yy, r_glowmapping ? "Yes" : "No", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
|
||||||
break;
|
|
||||||
case 12:
|
|
||||||
if (x==io) usemodels = 1-usemodels;
|
if (x==io) usemodels = 1-usemodels;
|
||||||
modval(0,1,(int32_t *)&usemodels,1,probey==io);
|
modval(0,1,(int32_t *)&usemodels,1,probey==io);
|
||||||
mgametextpal(d,yy, usemodels ? "Yes" : "No", MENUHIGHLIGHT(io), 0);
|
mgametextpal(d,yy, usemodels ? "Yes" : "No", MENUHIGHLIGHT(io), 0);
|
||||||
break;
|
break;
|
||||||
case 13:
|
|
||||||
enabled = usemodels;
|
|
||||||
if (enabled && x==io) r_animsmoothing = !r_animsmoothing;
|
|
||||||
if (enabled) modval(0,1,(int32_t *)&r_animsmoothing,1,probey==io);
|
|
||||||
mgametextpal(d,yy, r_animsmoothing ? "Yes" : "No", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
|
||||||
break;
|
|
||||||
case 14:
|
|
||||||
enabled = usemodels;
|
|
||||||
if (enabled && x==io) r_modelocclusionchecking = !r_modelocclusionchecking;
|
|
||||||
if (enabled) modval(0,1,(int32_t *)&r_modelocclusionchecking,1,probey==io);
|
|
||||||
mgametextpal(d,yy, r_modelocclusionchecking ? "Yes" : "No", enabled?MENUHIGHLIGHT(io):DISABLEDMENUSHADE, 0);
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -2857,9 +2865,9 @@ cheat_for_port_credits:
|
||||||
"Parental lock",
|
"Parental lock",
|
||||||
"-",
|
"-",
|
||||||
"Show inv & pickup messages",
|
"Show inv & pickup messages",
|
||||||
"HUD weapon display",
|
"Display current weapon",
|
||||||
"Use alternate HUD",
|
"Upgraded status bar",
|
||||||
"Use camera view in demos",
|
"Camera view in demos",
|
||||||
"-",
|
"-",
|
||||||
"DM: Ignore map votes",
|
"DM: Ignore map votes",
|
||||||
"DM: Use private messages",
|
"DM: Use private messages",
|
||||||
|
@ -2932,7 +2940,7 @@ cheat_for_port_credits:
|
||||||
}
|
}
|
||||||
modval(0,2,(int32_t *)&ud.drawweapon,1,probey==io);
|
modval(0,2,(int32_t *)&ud.drawweapon,1,probey==io);
|
||||||
{
|
{
|
||||||
char *s[] = { "Off", "Normal", "Icon only" };
|
char *s[] = { "Off", "On", "Icon only" };
|
||||||
mgametextpal(d,yy, s[ud.drawweapon], MENUHIGHLIGHT(io), 0);
|
mgametextpal(d,yy, s[ud.drawweapon], MENUHIGHLIGHT(io), 0);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue