Quake II RTX doxygen
1.0 dev
|
|
Go to the documentation of this file.
26 #include "refresh/images.h"
27 #include "refresh/models.h"
38 #define MODE_GEOMETRY 1
39 #define MODE_FULLSCREEN 2
40 #define MODE_MODELIST 4
58 unsigned long w, h, freq, depth;
84 if (!strncmp(
s,
"desktop", 7)) {
86 if (*
s && !Q_isspace(*
s)) {
87 Com_DPrintf(
"Mode %d is malformed\n", mode);
90 w = h = freq = depth = 0;
92 w = strtoul(
s, &
s, 10);
93 if (*
s !=
'x' && *
s !=
'X') {
94 Com_DPrintf(
"Mode %d is malformed\n", mode);
97 h = strtoul(
s + 1, &
s, 10);
100 freq = strtoul(
s + 1, &
s, 10);
102 depth = strtoul(
s + 1, &
s, 10);
104 }
else if (*
s ==
':') {
105 depth = strtoul(
s + 1, &
s, 10);
107 freq = strtoul(
s + 1, &
s, 10);
114 while (Q_isspace(*
s))
124 if (w < 64 || w > 8192 || h < 64 || h > 8192 || freq > 1000 || depth > 32) {
125 Com_DPrintf(
"Mode %lux%lu@%lu:%lu doesn't look sane\n", w, h, freq, depth);
163 w = strtoul(
s, &
s, 10);
164 if (*
s !=
'x' && *
s !=
'X') {
165 Com_DPrintf(
"Geometry string is malformed\n");
168 h = strtoul(
s + 1, &
s, 10);
171 if (*
s ==
'+' || *
s ==
'-') {
172 x = strtol(
s, &
s, 10);
173 if (*
s ==
'+' || *
s ==
'-') {
174 y = strtol(
s, &
s, 10);
179 if (w < 64 || w > 8192 || h < 64 || h > 8192) {
180 Com_DPrintf(
"Geometry %lux%lu doesn't look sane\n", w, h);
194 char buffer[MAX_QPATH];
199 Q_snprintf(buffer,
sizeof(buffer),
"%dx%d%+d%+d",
200 rc->width, rc->height, rc->x, rc->y);
315 CVAR_REFRESH | CVAR_ARCHIVE);
332 #if REF_GL && REF_VKPT
342 #error "REF_GL and REF_VKPT are both disabled, at least one has to be enableds"
403 qboolean(*
R_Init)(qboolean total) = NULL;
418 const char *string, qhandle_t font) = NULL;
432 byte* (*IMG_ReadPixels)(
int *
width,
int *
height,
int *rowbytes) = NULL;
436 qerror_t(*MOD_LoadMD3)(model_t *
model,
const void *rawdata,
size_t length) = NULL;
void(* R_TileClear)(int x, int y, int w, int h, qhandle_t pic)
void(* MOD_Reference)(model_t *model)
void(* R_EndRegistration)(void)
void VID_SetGeometry(vrect_t *rc)
cvar_t * Cvar_Set(const char *var_name, const char *value)
void(* R_SetColor)(uint32_t color)
qboolean(* R_InterceptKey)(unsigned key, qboolean down)
void(* R_SetSky)(const char *name, float rotate, vec3_t axis)
void(* R_SetAlpha)(float clpha)
size_t Q_snprintf(char *dest, size_t size, const char *fmt,...)
void(* IMG_Load)(image_t *image, byte *pic)
qboolean VID_GetGeometry(vrect_t *rc)
cvar_t * Cvar_Get(const char *var_name, const char *var_value, int flags)
void Z_LeakTest(memtag_t tag)
void(* R_ClearColor)(void)
void(* R_LightPoint)(vec3_t origin, vec3_t light)
char * VID_GetDefaultModeList(void)
qboolean(* R_Init)(qboolean total)
void(* R_DrawFill8)(int x, int y, int w, int h, int c)
float R_ClampScale(cvar_t *var)
void(* R_BeginFrame)(void)
void R_RegisterFunctionsRTX()
void(* R_AddDecal)(decal_t *d)
void VID_PumpEvents(void)
void(* R_SetAlphaScale)(float alpha)
qboolean VID_GetFullscreen(vrect_t *rc, int *freq_p, int *depth_p)
void Com_Error(error_type_t type, const char *fmt,...)
qerror_t(* MOD_LoadMD2)(model_t *model, const void *rawdata, size_t length)
void SCR_RegisterMedia(void)
float Cvar_ClampValue(cvar_t *var, float min, float max)
void Cbuf_AddText(cmdbuf_t *buf, const char *text)
void(* R_DrawPic)(int x, int y, qhandle_t pic)
int(* R_DrawString)(int x, int y, int flags, size_t maxChars, const char *string, qhandle_t font)
void(APIENTRY *qwglDrawBuffer)(GLenum mode)
void Cvar_SetByVar(cvar_t *var, const char *value, from_t from)
char * Com_GetLastError(void)
void(* R_DrawFill32)(int x, int y, int w, int h, uint32_t color)
void(* IMG_Unload)(image_t *image)
void VID_ToggleFullscreen(void)
void(* R_Shutdown)(qboolean total)
void CL_InitRefresh(void)
void(* R_RenderFrame)(refdef_t *fd)
void Com_SetLastError(const char *msg)
void(* R_BeginRegistration)(const char *map)
void(* R_SetClipRect)(const clipRect_t *clip)
void CL_ShutdownRefresh(void)
void(* R_DrawStretchPic)(int x, int y, int w, int h, qhandle_t pic)
void(* R_SetScale)(float scale)
void(* R_DrawChar)(int x, int y, int flags, int ch, qhandle_t font)
static void vid_modelist_changed(cvar_t *self)
static void vid_geometry_changed(cvar_t *self)
void CL_RestartRefresh(qboolean total)
CONST PIXELFORMATDESCRIPTOR int
void(* R_ModeChanged)(int width, int height, int flags, int rowbytes, void *pixels)
void Con_RegisterMedia(void)
void R_RegisterFunctionsGL()
static void vid_fullscreen_changed(cvar_t *self)