Quake II RTX doxygen
1.0 dev
|
|
Go to the documentation of this file.
23 #include "client/sound/vorbis.h"
24 #include "common/files.h"
25 #include "refresh/images.h"
53 char file_name[MAX_QPATH];
127 for (i = 0; i < numhnodes; i++)
159 int *node, *nodebase;
166 for (prev = 0; prev < 256; prev++)
173 for (j = 0; j < 256; j++)
180 while (numhnodes != 511)
182 node = nodebase + (numhnodes - 256) * 2;
214 int *hnodes, *hnodesbase;
218 count = in.
data[0] + (in.
data[1] << 8) + (in.
data[2] << 16) + (in.
data[3] << 24);
220 out_p = out.
data = Z_Malloc(count);
234 hnodes = hnodesbase + (nodenum << 9);
240 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
245 hnodes = hnodesbase + (nodenum << 9);
251 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
256 hnodes = hnodesbase + (nodenum << 9);
262 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
267 hnodes = hnodesbase + (nodenum << 9);
273 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
278 hnodes = hnodesbase + (nodenum << 9);
284 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
289 hnodes = hnodesbase + (nodenum << 9);
295 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
300 hnodes = hnodesbase + (nodenum << 9);
306 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
311 hnodes = hnodesbase + (nodenum << 9);
317 nodenum = hnodes[nodenum * 2 + (inbyte & 1)];
323 Com_Printf(
"Decompression overread by %i", (
input - in.
data) - in.
count);
342 byte compressed[0x20000];
346 int start, end, count;
355 command = LittleLong(command);
367 size = LittleLong(size);
368 if (size >
sizeof(compressed) || size < 1)
369 Com_Error(ERR_DROP,
"Bad compressed frame size");
381 in.
data = compressed;
389 uint32_t* wptr = rgba;
398 *wptr = MakeColor(src[0], src[1], src[2], 255);
490 if (!COM_CompareExtension(name,
".pcx"))
498 else if (!COM_CompareExtension(name,
".cin"))
511 Com_WPrintf(
"Cinematic \"%s\" not found. Skipping.\n", name);
qhandle_t R_RegisterRawImage(const char *name, int width, int height, byte *pic, imagetype_t type, imageflags_t flags)
cvar_t * Cvar_Set(const char *var_name, const char *value)
qhandle_t image_precache[MAX_IMAGES]
void SCR_StopCinematic(void)
size_t Q_snprintf(char *dest, size_t size, const char *fmt,...)
ssize_t FS_Read(void *buf, size_t len, qhandle_t f)
uint32_t d_8to24table[256]
void SCR_EndLoadingPlaque(void)
void SCR_RunCinematic(void)
ssize_t FS_FOpenFile(const char *name, qhandle_t *f, unsigned mode)
char file_name[MAX_QPATH]
void Com_Error(error_type_t type, const char *fmt,...)
void S_UnqueueRawSamples()
void SCR_FinishCinematic(void)
cblock_t Huff1Decompress(cblock_t in)
char * va(const char *format,...)
int SmallestNode1(int numhnodes)
void Con_Close(qboolean force)
qhandle_t SCR_ReadNextFrame(void)
void SCR_PlayCinematic(const char *name)
void Huff1TableInit(void)
void R_UnregisterImage(qhandle_t handle)
unsigned samples[LAG_WIDTH]
void SCR_BeginLoadingPlaque(void)
void CL_ClientCommand(const char *string)
void FS_FCloseFile(qhandle_t f)
float Cvar_VariableValue(const char *var_name)
void S_RawSamples(int samples, int rate, int width, int channels, byte *data, float volume)