mirror of
https://git.code.sf.net/p/quake/quakeforge-old
synced 2025-02-16 16:51:16 +00:00
Changed options_menu to VID_options_menu.
Made it start at 0 instead of 13. Added support for 800x600 resolution.
This commit is contained in:
parent
08c6bbd84b
commit
e144f6ceee
1 changed files with 13 additions and 8 deletions
|
@ -48,7 +48,7 @@ static fxMesaContext fc = NULL;
|
||||||
static int scr_width, scr_height;
|
static int scr_width, scr_height;
|
||||||
static qboolean is8bit = 0;
|
static qboolean is8bit = 0;
|
||||||
|
|
||||||
int options_items = 13;
|
int VID_options_items = 0;
|
||||||
|
|
||||||
/*-----------------------------------------------------------------------*/
|
/*-----------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
@ -266,24 +266,29 @@ void GL_EndRendering (void)
|
||||||
fxMesaSwapBuffers();
|
fxMesaSwapBuffers();
|
||||||
}
|
}
|
||||||
|
|
||||||
#define NUM_RESOLUTIONS 3
|
static int resolutions[][3]={
|
||||||
|
|
||||||
static int resolutions[NUM_RESOLUTIONS][3]={
|
|
||||||
{ 512, 384, GR_RESOLUTION_512x384 },
|
{ 512, 384, GR_RESOLUTION_512x384 },
|
||||||
{ 640, 400, GR_RESOLUTION_640x400 },
|
{ 640, 400, GR_RESOLUTION_640x400 },
|
||||||
{ 640, 480, GR_RESOLUTION_640x480 }
|
{ 640, 480, GR_RESOLUTION_640x480 },
|
||||||
|
{ 800, 600, GR_RESOLUTION_800x600 }
|
||||||
};
|
};
|
||||||
|
|
||||||
int findres(int *width, int *height)
|
#define NUM_RESOLUTIONS (sizeof(resolutions)/(sizeof(int)*3))
|
||||||
|
|
||||||
|
|
||||||
|
static int
|
||||||
|
findres(int *width, int *height)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for(i=0;i<NUM_RESOLUTIONS;i++)
|
for(i=0; i < NUM_RESOLUTIONS; i++) {
|
||||||
if((*width<=resolutions[i][0]) && (*height<=resolutions[i][1])) {
|
if((*width <= resolutions[i][0]) &&
|
||||||
|
(*height <= resolutions[i][1])) {
|
||||||
*width = resolutions[i][0];
|
*width = resolutions[i][0];
|
||||||
*height = resolutions[i][1];
|
*height = resolutions[i][1];
|
||||||
return resolutions[i][2];
|
return resolutions[i][2];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
*width = 640;
|
*width = 640;
|
||||||
*height = 480;
|
*height = 480;
|
||||||
|
|
Loading…
Reference in a new issue